Skip to content

Commit

Permalink
fix: fixed CI Node Setup and Caching (#1215)
Browse files Browse the repository at this point in the history
  • Loading branch information
Phillip9587 authored Jan 17, 2022
1 parent 29760c6 commit e99e226
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 20 deletions.
6 changes: 1 addition & 5 deletions .github/workflows/ci_checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,17 +23,13 @@ jobs:

agents:
runs-on: ubuntu-latest
name: Agent
name: Agent ${{ matrix.agent }}
timeout-minutes: 15
strategy:
matrix:
agent: [1, 2, 3]
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ env.node_version }}
uses: actions/setup-node@v2
with:
node-version: ${{ env.node_version }}
- uses: ./.github/workflows/setup
with:
node_version: ${{ env.node_version }}
Expand Down
24 changes: 9 additions & 15 deletions .github/workflows/setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,23 +6,17 @@ inputs:
required: true
default: '14'
runs:
using: 'composite'
using: composite
steps:
- name: Derive appropriate SHAs for base and head for `nx affected` commands
uses: nrwl/nx-set-shas@v2
with:
main-branch-name: 'master'
- uses: actions/setup-node@v1
- name: Use Node.js ${{ inputs.node_version }}
uses: actions/setup-node@v2
with:
node-version: ${{ inputs.node_version }}
- uses: actions/cache@v2
id: workspace-cache
with:
path: |
node_modules
!node_modules/.cache
key: ${{ runner.os }}-node-${{ inputs.node_version }}-workspace-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-node-${{ inputs.node_version }}-workspace-
check-latest: true
cache: yarn
- run: yarn install --frozen-lockfile
shell: bash
- name: Derive appropriate SHAs for base and head for `nx affected` commands
uses: nrwl/nx-set-shas@v2
with:
main-branch-name: 'master'

0 comments on commit e99e226

Please sign in to comment.