Skip to content

Commit

Permalink
Sign the release (#86)
Browse files Browse the repository at this point in the history
* Sign the release

* Update release-candidate.yml

* Update codeql.yml

* Update dependency-review.yml
  • Loading branch information
fatihtokus authored Aug 1, 2024
1 parent 973cd78 commit 9b32759
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# the `language` matrix defined below to confirm you have the correct set of
# supported CodeQL languages.
#
name: "CodeQL"
name: CodeQL

on:
push:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/dependency-review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# PRs introducing known-vulnerable packages will be blocked from merging.
#
# Source repository: https://github.com/actions/dependency-review-action
name: 'Dependency Review'
name: Dependency Review
on: [pull_request]

permissions:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-candidate.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Release
name: Release-Candidate

on:
push:
Expand Down
25 changes: 24 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ jobs:
# copy js files
cat
{
# copy report file except the last 4 lines
# copy report file except for the last 4 lines
head -n -4 'src/frontend-app/dist/src/assets/app-template.html'
echo ''
cat 'src/frontend-app/dist/app.js'
Expand All @@ -58,9 +58,32 @@ jobs:
cat "$reportTemplate"
- name: Compress
run: tar -zcvf scan2html.tar.gz scan2html.sh "$reportTemplate" LICENSE plugin.yaml

- name: Install GPG
run: sudo apt-get install -y gnupg

- name: Configure GPG
run: |
mkdir -p ~/.gnupg
chmod 700 ~/.gnupg
echo "use-agent" > ~/.gnupg/gpg.conf
echo "pinentry-mode loopback" >> ~/.gnupg/gpg.conf
- name: Import GPG key
run: |
echo "${{ secrets.GPG_PRIVATE_KEY }}" | gpg --batch --yes --import
env:
GPG_PRIVATE_KEY: ${{ secrets.GPG_PRIVATE_KEY }}

- name: Sign the release file
run: |
gpg --batch --yes --pinentry-mode loopback --passphrase "${{ secrets.GPG_PASSPHRASE }}" --armor --detach-sign scan2html.tar.gz
env:
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}

- name: Release
uses: softprops/action-gh-release@de2c0eb89ae2a093876385947365aca7b0e5f844 # v1
with:
files: |
scan2html.tar.gz
scan2html.tar.gz.asc

0 comments on commit 9b32759

Please sign in to comment.