Browse Source

build(github): Update outdated references to nvmrc (#20194)

Update to use `volta` instead of outdated reference to `nvm`
Billy Vong 4 years ago
parent
commit
f4ad604206
2 changed files with 8 additions and 22 deletions
  1. 4 11
      .github/workflows/acceptance.yml
  2. 4 11
      .github/workflows/javascript.yml

+ 4 - 11
.github/workflows/acceptance.yml

@@ -12,18 +12,16 @@ jobs:
         VISUAL_SNAPSHOT_ENABLE: 1
       steps:
         # Checkout codebase
-        - uses: actions/checkout@v1
+        - uses: actions/checkout@v2
+
+        # Install/setup node
+        - uses: volta-cli/action@v1
 
         # See https://github.com/actions/cache/blob/master/examples.md#node---yarn for example
         - name: Get yarn cache directory path
           id: yarn-cache-dir-path
           run: echo "::set-output name=dir::$(yarn cache dir)"
 
-        # Use nvmrc so we don't have yet another place node version is defined
-        - name: Get node version from .nvmrc
-          id: nvmrc
-          run: echo "::set-output name=version::$(cat .nvmrc)"
-
         # yarn cache
         - uses: actions/cache@v1
           id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
@@ -33,11 +31,6 @@ jobs:
             restore-keys: |
               ${{ runner.os }}-yarn-
 
-        # Setup node
-        - uses: actions/setup-node@v1
-          with:
-            node-version: ${{ steps.nvmrc.outputs.version }}
-
         - name: Install dependencies
           run: yarn install --frozen-lockfile
 

+ 4 - 11
.github/workflows/javascript.yml

@@ -9,18 +9,16 @@ jobs:
       runs-on: ubuntu-latest
       steps:
         # Checkout codebase
-        - uses: actions/checkout@v1
+        - uses: actions/checkout@v2
+
+        # Install/setup node
+        - uses: volta-cli/action@v1
 
         # See https://github.com/actions/cache/blob/master/examples.md#node---yarn for example
         - name: Get yarn cache directory path
           id: yarn-cache-dir-path
           run: echo "::set-output name=dir::$(yarn cache dir)"
 
-        # Use nvmrc so we don't have yet another place node version is defined
-        - name: Get node version from .nvmrc
-          id: nvmrc
-          run: echo "::set-output name=version::$(cat .nvmrc)"
-
         # yarn cache
         - uses: actions/cache@v1
           id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
@@ -30,11 +28,6 @@ jobs:
             restore-keys: |
               ${{ runner.os }}-yarn-
 
-        # Setup node
-        - uses: actions/setup-node@v1
-          with:
-            node-version: ${{ steps.nvmrc.outputs.version }}
-
         - name: Install dependencies
           run: yarn install --frozen-lockfile