From 3c410d390fea1840ec1ecacf3880f89cf09c9b8b Mon Sep 17 00:00:00 2001 From: Jack Bates Date: Thu, 17 Feb 2022 15:23:36 -0700 Subject: [PATCH 1/2] Fix CI: npm ERR! Unexpected token '.' --- .github/workflows/main.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 66ff694c..e2798f3d 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -8,9 +8,12 @@ jobs: runs-on: ${{matrix.os}} steps: - uses: actions/checkout@v2 - - uses: dcodeIO/setup-node-nvm@master + - name: Use Node.js ${{matrix.node}} + uses: actions/setup-node@v2 with: node-version: ${{matrix.node}} + #cache: npm + - run: npm install -g npm@7 # https://github.com/npm/cli/issues/4341#issuecomment-1040608101 - run: npm install -g npm - run: npm install - run: npm test @@ -22,4 +25,4 @@ jobs: - windows-latest node: - lts/erbium - - node + - lts/* From 6747d249e8176a8fa24498b4ac37c55ed0d48df5 Mon Sep 17 00:00:00 2001 From: Titus Date: Fri, 25 Feb 2022 15:24:34 +0100 Subject: [PATCH 2/2] Apply suggestions from code review --- .github/workflows/main.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index e2798f3d..ca0da637 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -8,12 +8,10 @@ jobs: runs-on: ${{matrix.os}} steps: - uses: actions/checkout@v2 - - name: Use Node.js ${{matrix.node}} - uses: actions/setup-node@v2 + - uses: actions/setup-node@v2 with: node-version: ${{matrix.node}} - #cache: npm - - run: npm install -g npm@7 # https://github.com/npm/cli/issues/4341#issuecomment-1040608101 + - run: npm install -g npm@7 # See: - run: npm install -g npm - run: npm install - run: npm test