Debian Codegraph @

.github/workflows/autorelease.yml

raw symbols SCIP
1 # This is a basic workflow to help you get started with Actions
2
3 name: release gopass-hibp
4
5 # Controls when the action will run.
6 on:
7 # Triggers the workflow on tags starting with v, i.e. release tags
8 push:
9 tags:
10 - 'v*'
11
12 jobs:
13 goreleaser:
14 runs-on: ubuntu-latest
15 steps:
16 - name: Harden Runner
17 uses: step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
18 with:
19 egress-policy: audit
20
21 -
22 name: Checkout
23 uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
24 with:
25 fetch-depth: 0
26 -
27 name: Set up Go
28 uses: actions/setup-go@4dc6199c7b1a012772edbd06daecab0f50c9053c # v6.1.0
29 with:
30 go-version: '1.24'
31 - uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
32 with:
33 path: ~/go/pkg/mod
34 key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
35 restore-keys: |
36 ${{ runner.os }}-go-
37 - uses: sigstore/cosign-installer@faadad0cce49287aee09b3a48701e75088a2c6ad # v4.0.0
38 - uses: anchore/sbom-action/download-syft@8e94d75ddd33f69f691467e42275782e4bfefe84 # v0.20.9
39 -
40 name: Import GPG signing key
41 id: import_gpg
42 uses: crazy-max/ghaction-import-gpg@e89d40939c28e39f97cf32126055eeae86ba74ec # v6.3.0
43 with:
44 gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
45 passphrase: ${{ secrets.PASSPHRASE }}
46 -
47 name: Debug
48 run: |
49 echo "GPG ---------------------"
50 echo "fingerprint: ${{ steps.import_gpg.outputs.fingerprint }}"
51 echo "keyid: ${{ steps.import_gpg.outputs.keyid }}"
52 echo "name: ${{ steps.import_gpg.outputs.name }}"
53 echo "email: ${{ steps.import_gpg.outputs.email }}"
54 echo "Go env ------------------"
55 pwd
56 echo ${HOME}
57 echo ${GITHUB_WORKSPACE}
58 echo ${GOPATH}
59 echo ${GOROOT}
60 env
61 -
62 name: Generate release-notes
63 run: |
64 go run helpers/changelog/main.go >../RELEASE_NOTES
65 -
66 name: Run GoReleaser
67 uses: goreleaser/goreleaser-action@e435ccd777264be153ace6237001ef4d979d3a7a # v6.4.0
68 with:
69 version: latest
70 args: release --release-notes=../RELEASE_NOTES
71 env:
72 GITHUB_TOKEN: ${{ secrets.GH_PAT }}
73 GPG_FINGERPRINT: ${{ steps.import_gpg.outputs.fingerprint }}
74 GOPATH: /home/runner/go
75 -
76 name: "Upload deb files to apt hosting"
77 run: |
78 for D in dist/*.deb; do
79 curl -H"X-Filename: ${D}" -H"X-Apikey: ${APIKEY}" -XPOST --data-binary @$D https://packages.gopass.pw/repos/gopass/upload
80 curl -H"X-Filename: ${D}" -H"X-Apikey: ${APIKEY}" -XPOST --data-binary @$D https://packages.gopass.pw/repos/gopass-unstable/upload
81 done
82 env:
83 APIKEY: ${{ secrets.APT_APIKEY }}