From 179908fc1a9cbcd8afd808b5a5997e6bd7331b39 Mon Sep 17 00:00:00 2001 From: Michael Scott Hertzberg Date: Wed, 25 Oct 2023 13:04:35 -0400 Subject: [PATCH] chore: update github workflow for build and test --- .github/workflows/build.yml | 24 ++++++++++-------------- 1 file changed, 10 insertions(+), 14 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b3d9e4e..c9e735f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -3,15 +3,10 @@ name: Node.js CI -on: - push: - branches: [ "main" ] - pull_request: - branches: [ "main" ] +on: [push] jobs: build: - runs-on: ubuntu-latest strategy: @@ -20,11 +15,12 @@ jobs: # 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 run build --if-present - - run: npm test:ci + - 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 install + - run: npm run build --if-present + - run: npm test:ci --if-present