From 7385986cf53fce9d355b8e7e05871fd832d4d149 Mon Sep 17 00:00:00 2001 From: John Gardner Date: Fri, 21 Jun 2024 17:16:30 -0700 Subject: [PATCH] try to run analyzer on PR as well? --- .github/workflows/template-validation.yaml | 2 +- .github/workflows/template-warnings.yaml | 35 ++++++++++++++++++++++ 2 files changed, 36 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/template-warnings.yaml diff --git a/.github/workflows/template-validation.yaml b/.github/workflows/template-validation.yaml index a2e601c17b..4d1ef6d296 100644 --- a/.github/workflows/template-validation.yaml +++ b/.github/workflows/template-validation.yaml @@ -15,7 +15,7 @@ jobs: strategy: matrix: - node-version: [12.x] + node-version: [20.x] steps: - uses: actions/checkout@v2 diff --git a/.github/workflows/template-warnings.yaml b/.github/workflows/template-warnings.yaml new file mode 100644 index 0000000000..a74c47ebe4 --- /dev/null +++ b/.github/workflows/template-warnings.yaml @@ -0,0 +1,35 @@ +# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node +# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions + +name: Template Validation + +on: + pull_request: + push: + branches: master + +jobs: + build: + + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [20.x] + + steps: + - uses: actions/checkout@v4 + + - name: Get changed files + id: changed-files + uses: tj-actions/changed-files@v44 + # To compare changes between the current commit and the last pushed remote commit set `since_last_remote_commit: true`. e.g + with: + since_last_remote_commit: true + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v1 + with: + working-directory: ./scripts + node-version: ${{ matrix.node-version }} + - run: npm install + - run: npm run analyze ${{ steps.changed-files.outputs.all_changed_files }} \ No newline at end of file