Skip to content

Commit

Permalink
mac sign and notarize
Browse files Browse the repository at this point in the history
  • Loading branch information
vedantmgoyal9 committed Feb 13, 2025
1 parent 4d9f189 commit 6c96300
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 7 deletions.
14 changes: 7 additions & 7 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,13 @@ jobs:
fail-fast: false
outputs:
cache-hit: ${{ steps.cache-check.outputs.cache-hit }}
env:
GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}
MACOS_SIGN_P12: ${{ secrets.MACOS_SIGN_P12 }}
MACOS_SIGN_PASSWORD: ${{ secrets.MACOS_SIGN_PASSWORD }}
MACOS_NOTARY_ISSUER_ID: ${{ secrets.MACOS_NOTARY_ISSUER_ID }}
MACOS_NOTARY_KEY: ${{ secrets.MACOS_NOTARY_KEY }}
MACOS_NOTARY_KEY_ID: ${{ secrets.MACOS_NOTARY_KEY_ID }}
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -54,18 +61,12 @@ jobs:
distribution: goreleaser-pro
version: nightly
args: release --clean --split ${{ matrix._ids }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}
- if: (github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' || (github.event_name == 'push' && !startsWith(github.ref, 'refs/tags/v'))) && steps.cache-check.outputs.cache-hit != 'true'
uses: goreleaser/[email protected]
with:
distribution: goreleaser-pro
version: nightly
args: release --clean --split ${{ matrix._ids }} --nightly --skip=winget
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}
release:
# skip if cache exists for same commit, since we probably already released
if: needs.build.outputs.cache-hit != 'true'
Expand Down Expand Up @@ -110,4 +111,3 @@ jobs:
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}
# macos notarization env vars
12 changes: 12 additions & 0 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,18 @@ dmg:
- name: "{{ .ProjectName }}"
use: appbundle

notarize:
macos:
- enabled: '{{ isEnvSet "MACOS_SIGN_P12" }}'
sign:
certificate: '{{ .Env.MACOS_SIGN_P12 }}'
password: '{{ .Env.MACOS_SIGN_PASSWORD }}'
notarize:
issuer_id: '{{ .Env.MACOS_NOTARY_ISSUER_ID }}'
key: '{{ .Env.MACOS_NOTARY_KEY }}'
key_id: '{{ .Env.MACOS_NOTARY_KEY_ID }}'
wait: false

app_bundles:
- icon: ./misc/osx/Rio.app/Contents/Resources/icon.icns
bundle: com.raphaelamorim.rio
Expand Down

0 comments on commit 6c96300

Please sign in to comment.