ci: harden zip command with -n

from the man unzip:

 -n stands for never overwrite existing files.  If a file already exists,
 skip the extraction of that file without prompting.
This commit is contained in:
Jose Storopoli 2024-07-17 17:40:07 -03:00
parent 4edd504cb6
commit 8a91015769
No known key found for this signature in database
GPG Key ID: BCD6BC0FC1D110A5
1 changed files with 1 additions and 1 deletions

View File

@ -50,7 +50,7 @@ jobs:
fs.writeFileSync(`${process.env.GITHUB_WORKSPACE}/semver-break.zip`, Buffer.from(download.data)); fs.writeFileSync(`${process.env.GITHUB_WORKSPACE}/semver-break.zip`, Buffer.from(download.data));
- name: "Unzip artifact" - name: "Unzip artifact"
if: ${{ hashFiles('semver-break.zip') != '' }} if: ${{ hashFiles('semver-break.zip') != '' }}
run: unzip semver-break.zip run: unzip -n semver-break.zip
- name: "Comment and add label on PR - Semver break" - name: "Comment and add label on PR - Semver break"
uses: actions/github-script@v7 uses: actions/github-script@v7
if: ${{ hashFiles('semver-break') != '' }} if: ${{ hashFiles('semver-break') != '' }}