sethvargo / ratchet

A tool for securing CI/CD workflows with version pinning.
Apache License 2.0
772 stars 32 forks source link

exclude not working #16

Closed davidkarlsen closed 2 years ago

davidkarlsen commented 2 years ago

TL;DR

uses: 'github/codeql-action/analyze@v2' # ratchet:exclude

becomes:

       - name: Initialize CodeQL
         if: github.ref != 'refs/heads/master'
-        uses: 'github/codeql-action/init@v2' # ratchet:exclude
+        uses: 'exclude'

when running

ratchet update build.yaml

Expected behavior

should preserve existing config

Observed behavior

becomes invalid

Version

0.2.0

On what operating system are you using ratchet?

Mac OS

CI/CD workflow file

N/A

Relevant log output

N/A

Additional information

N/A

davidkarlsen commented 2 years ago

Note that it actually works correct when running ratchet pin -out build-test.yaml build.yaml