0.3.0 (2026-08-06) #20
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Release workflow: publish signed/notarized release assets. | |
| # Preview/CI artifacts are handled by parity.yml. | |
| name: release | |
| on: | |
| release: | |
| types: [published] | |
| permissions: | |
| contents: write | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - goos: linux | |
| goarch: amd64 | |
| notarize: false | |
| ext: "" | |
| - goos: linux | |
| goarch: arm64 | |
| notarize: false | |
| ext: "" | |
| - goos: linux | |
| goarch: 386 | |
| notarize: false | |
| ext: "" | |
| - goos: linux | |
| goarch: arm | |
| goarm: "7" | |
| notarize: false | |
| ext: "" | |
| - goos: darwin | |
| goarch: amd64 | |
| notarize: true | |
| ext: "" | |
| - goos: darwin | |
| goarch: arm64 | |
| notarize: true | |
| ext: "" | |
| - goos: windows | |
| goarch: amd64 | |
| notarize: false | |
| ext: ".exe" | |
| - goos: windows | |
| goarch: arm64 | |
| notarize: false | |
| ext: ".exe" | |
| - goos: windows | |
| goarch: 386 | |
| notarize: false | |
| ext: ".exe" | |
| - goos: freebsd | |
| goarch: amd64 | |
| notarize: false | |
| ext: "" | |
| - goos: freebsd | |
| goarch: arm64 | |
| notarize: false | |
| ext: "" | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v7 | |
| - name: Set up Go | |
| uses: actions/setup-go@v6 | |
| with: | |
| go-version-file: go.mod | |
| - name: Build binary | |
| env: | |
| GOOS: ${{ matrix.goos }} | |
| GOARCH: ${{ matrix.goarch }} | |
| GOARM: ${{ matrix.goarm }} | |
| CGO_ENABLED: "0" | |
| BIN_EXT: ${{ matrix.ext }} | |
| run: | | |
| mkdir -p dist | |
| if [ "$GOARCH" = "arm" ] && [ -n "$GOARM" ]; then | |
| OUTPUT_NAME="apprise-go-${GOOS}-${GOARCH}v${GOARM}${BIN_EXT}" | |
| else | |
| OUTPUT_NAME="apprise-go-${GOOS}-${GOARCH}${BIN_EXT}" | |
| fi | |
| go build -trimpath -ldflags "-s -w" -o "dist/${OUTPUT_NAME}" ./cmd/apprise | |
| - name: Write signing certificate | |
| if: matrix.notarize | |
| env: | |
| APPLE_BUILD_CERTIFICATE_BASE64: ${{ secrets.APPLE_BUILD_CERTIFICATE_BASE64 }} | |
| run: | | |
| printf '%s' "$APPLE_BUILD_CERTIFICATE_BASE64" | base64 --decode > apple_codesign.p12 | |
| chmod 600 apple_codesign.p12 | |
| - name: Write App Store Connect API key | |
| if: matrix.notarize | |
| env: | |
| APP_STORE_CONNECT_KEY_JSON: ${{ secrets.APPLE_APP_STORE_CONNECT_KEY_JSON }} | |
| run: | | |
| printf '%s' "$APP_STORE_CONNECT_KEY_JSON" > app_store_connect_key.json | |
| chmod 600 app_store_connect_key.json | |
| - name: Set output name | |
| id: set-output-name | |
| run: | | |
| if [ "${{ matrix.goarch }}" = "arm" ] && [ -n "${{ matrix.goarm }}" ]; then | |
| OUTPUT_NAME="apprise-go-${{ matrix.goos }}-${{ matrix.goarch }}v${{ matrix.goarm }}${{ matrix.ext }}" | |
| else | |
| OUTPUT_NAME="apprise-go-${{ matrix.goos }}-${{ matrix.goarch }}${{ matrix.ext }}" | |
| fi | |
| echo "output_name=${OUTPUT_NAME}" >> $GITHUB_OUTPUT | |
| - name: Sign darwin binary | |
| if: matrix.notarize | |
| uses: indygreg/apple-code-sign-action@v1 | |
| with: | |
| input_path: dist/${{ steps.set-output-name.outputs.output_name }} | |
| p12_file: apple_codesign.p12 | |
| p12_password: ${{ secrets.APPLE_BUILD_CERTIFICATE_PASSWORD }} | |
| sign_args: --code-signature-flags=runtime | |
| notarize: false | |
| - name: Zip darwin binary | |
| if: matrix.notarize | |
| run: | | |
| zip -j "dist/${{ steps.set-output-name.outputs.output_name }}.zip" \ | |
| "dist/${{ steps.set-output-name.outputs.output_name }}" | |
| - name: Notarize darwin zip | |
| if: matrix.notarize | |
| uses: indygreg/apple-code-sign-action@v1 | |
| with: | |
| input_path: dist/${{ steps.set-output-name.outputs.output_name }}.zip | |
| sign: false | |
| notarize: true | |
| app_store_connect_api_key_json_file: app_store_connect_key.json | |
| - name: Cleanup signing materials | |
| if: always() | |
| run: rm -f apple_codesign.p12 app_store_connect_key.json | |
| - name: Upload release asset (darwin zip) | |
| if: github.event_name == 'release' && matrix.notarize | |
| uses: softprops/action-gh-release@v3 | |
| with: | |
| files: dist/${{ steps.set-output-name.outputs.output_name }}.zip | |
| - name: Upload release asset (non-darwin) | |
| if: github.event_name == 'release' && !matrix.notarize | |
| uses: softprops/action-gh-release@v3 | |
| with: | |
| files: dist/${{ steps.set-output-name.outputs.output_name }} |