File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2525 steps :
2626 - name : Checkout
2727 uses : actions/checkout@v5
28+ with :
29+ fetch-depth : 2 # need to fetch 2 to get list of changed files
30+
31+ - name : Get changed files
32+ id : changed_files
33+ run : |
34+ firstCommit='${{ github.event.pull_request.base.sha }}'
35+ lastCommit='${{ github.event.pull_request.head.sha }}'
36+ changedFiles=$(git diff --name-only --diff-filter=d "${firstCommit}" "${lastCommit}")
37+ echo "Changed files: ${changedFiles}"
38+ echo "CHANGED_FILES=${changedFiles}" >> "${GITHUB_OUTPUT}"
2839
2940 - name : Download problem matchers
3041 shell : bash
@@ -286,6 +297,12 @@ jobs:
286297
287298 exit ${error}
288299
300+ - name : linelint
301+ if : always()
302+ run : |
303+ go get github.com/fernandrone/linelint
304+ linelint ${{ steps.changed_files.outputs.CHANGED_FILES }}
305+
289306 - name : PowerShell - PSScriptAnalyzer
290307 if : always()
291308 shell : pwsh
You can’t perform that action at this time.
0 commit comments