3535 # or posted in a PR (pull_request)
3636 APPLY_FIXES_MODE : commit
3737
38+ ACTION_ZIZMOR_UNSECURED_ENV_VARIABLES : ' GITHUB_TOKEN'
39+
3840concurrency :
3941 group : ${{ github.ref }}-${{ github.workflow }}
4042 cancel-in-progress : true
@@ -47,20 +49,21 @@ jobs:
4749 steps :
4850 # Git Checkout
4951 - name : Checkout Code
50- uses : actions/checkout@v7
52+ uses : actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
5153 with :
5254 token : ${{ secrets.PAT || secrets.GITHUB_TOKEN }}
5355
5456 # If you use VALIDATE_ALL_CODEBASE = true, you can remove this line to
5557 # improve performance
5658 fetch-depth : 0
59+ persist-credentials : false
5760
5861 # MegaLinter
5962 - name : MegaLinter
6063
6164 # You can override MegaLinter flavor used to have faster performances
6265 # More info at https://megalinter.io/latest/flavors/
63- uses : oxsecurity/megalinter/flavors/java@v9
66+ uses : oxsecurity/megalinter/flavors/java@ef3e84b8b836d76db562d0f3ed7da61e8fd538bc # v9.6.0
6467
6568 id : ml
6669
98101
99102 # Upload MegaLinter artifacts
100103 - name : Archive production artifacts
101- uses : actions/upload-artifact@v6
104+ uses : actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
102105 if : success() || failure()
103106 with :
104107 name : MegaLinter reports
@@ -110,7 +113,7 @@ jobs:
110113 # Create pull request if applicable
111114 # (for now works only on PR from same repository, not from forks)
112115 - name : Create Pull Request with applied fixes
113- uses : peter-evans/create-pull-request@v8
116+ uses : peter-evans/create-pull-request@5f6978faf089d4d20b00c7766989d076bb2fc7f1 # v8.1.1
114117 id : cpr
115118 if : >-
116119 steps.ml.outputs.has_updated_sources == 1 &&
@@ -144,8 +147,11 @@ jobs:
144147 ) &&
145148 !contains(github.event.head_commit.message, 'skip fix')
146149 run : |
147- echo "PR Number - ${{ steps.cpr.outputs.pull-request-number }}"
148- echo "PR URL - ${{ steps.cpr.outputs.pull-request-url }}"
150+ echo "PR Number - ${STEPS_CPR_OUTPUTS_PULL_REQUEST_NUMBER}"
151+ echo "PR URL - ${STEPS_CPR_OUTPUTS_PULL_REQUEST_URL}"
152+ env :
153+ STEPS_CPR_OUTPUTS_PULL_REQUEST_NUMBER : ${{ steps.cpr.outputs.pull-request-number }}
154+ STEPS_CPR_OUTPUTS_PULL_REQUEST_URL : ${{ steps.cpr.outputs.pull-request-url }}
149155
150156 # Push new commit if applicable
151157 # (for now works only on PR from same repository, not from forks)
@@ -166,7 +172,7 @@ jobs:
166172 run : sudo chown -Rc $UID .git/
167173
168174 - name : Commit and push applied linter fixes
169- uses : stefanzweifel/git-auto-commit-action@v6
175+ uses : stefanzweifel/git-auto-commit-action@778341af668090896ca464160c2def5d1d1a3eb0 # v6.0.1
170176 if : >-
171177 steps.ml.outputs.has_updated_sources == 1 &&
172178 (
0 commit comments