From 4761986a33679b903914152a1b2c002b1b7e256d Mon Sep 17 00:00:00 2001 From: Sakshi Shreya Date: Sat, 13 Apr 2024 01:04:46 +0530 Subject: [PATCH 1/3] Create node.js.yml --- .github/workflows/node.js.yml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .github/workflows/node.js.yml diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml new file mode 100644 index 0000000..fc2d85f --- /dev/null +++ b/.github/workflows/node.js.yml @@ -0,0 +1,31 @@ +# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs + +name: Node.js CI + +on: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] + +jobs: + build: + + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [14.x, 16.x, 18.x] + # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ + + steps: + - uses: actions/checkout@v3 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + cache: 'npm' + - run: npm ci + - run: npm run start --if-present + - run: npm test From 36948929adcaaac1075149c9c4f3cb6b3e862668 Mon Sep 17 00:00:00 2001 From: Sakshi Shreya Date: Sat, 13 Apr 2024 01:05:43 +0530 Subject: [PATCH 2/3] Update node.js.yml --- .github/workflows/node.js.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index fc2d85f..f0f0e6a 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -28,4 +28,3 @@ jobs: cache: 'npm' - run: npm ci - run: npm run start --if-present - - run: npm test From d37b1b231ff7a5c9cad0562c0f5c1132862662fe Mon Sep 17 00:00:00 2001 From: Sakshi Shreya Date: Sat, 13 Apr 2024 01:06:51 +0530 Subject: [PATCH 3/3] Update node.js.yml --- .github/workflows/node.js.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index f0f0e6a..6ea30da 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -16,7 +16,7 @@ jobs: strategy: matrix: - node-version: [14.x, 16.x, 18.x] + node-version: [16.x, 18.x] # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ steps: