fix(ci): Move to maintained get-changed files.

This commit is contained in:
Peter Johanson 2024-01-26 07:53:59 +00:00 committed by Pete Johanson
parent 1f8b45d57d
commit 72d5c01e46

View file

@ -409,19 +409,20 @@ jobs:
if: ${{ github.event_name != 'schedule' }} if: ${{ github.event_name != 'schedule' }}
runs-on: ubuntu-latest runs-on: ubuntu-latest
outputs: outputs:
changed-files: ${{ steps.changed-files.outputs.all }} changed-files: ${{ steps.changed-files.outputs.all_changed_files }}
board-changes: ${{ steps.board-changes.outputs.result }} board-changes: ${{ steps.board-changes.outputs.result }}
core-changes: ${{ steps.core-changes.outputs.result }} core-changes: ${{ steps.core-changes.outputs.result }}
steps: steps:
- uses: Ana06/get-changed-files@v2.0.0 - uses: tj-actions/changed-files@v42
id: changed-files id: changed-files
with: with:
format: "json" json: true
escape_json: false
- uses: actions/github-script@v7 - uses: actions/github-script@v7
id: board-changes id: board-changes
with: with:
script: | script: |
const changedFiles = JSON.parse(`${{ steps.changed-files.outputs.all }}`); const changedFiles = JSON.parse(`${{ steps.changed-files.outputs.all_changed_files }}`);
const boardChanges = changedFiles.filter(f => f.startsWith('app/boards')); const boardChanges = changedFiles.filter(f => f.startsWith('app/boards'));
return boardChanges.length ? 'true' : 'false'; return boardChanges.length ? 'true' : 'false';
result-encoding: string result-encoding: string
@ -429,7 +430,7 @@ jobs:
id: core-changes id: core-changes
with: with:
script: | script: |
const changedFiles = JSON.parse(`${{ steps.changed-files.outputs.all }}`); const changedFiles = JSON.parse(`${{ steps.changed-files.outputs.all_changed_files }}`);
const boardChanges = changedFiles.filter(f => f.startsWith('app/boards')); const boardChanges = changedFiles.filter(f => f.startsWith('app/boards'));
const appChanges = changedFiles.filter(f => f.startsWith('app')); const appChanges = changedFiles.filter(f => f.startsWith('app'));
const ymlChanges = changedFiles.includes('.github/workflows/build.yml'); const ymlChanges = changedFiles.includes('.github/workflows/build.yml');