Use binary artifacts for releases #32
Workflow file for this run
This file contains 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
name: Feature branch | ||
on: | ||
workflow_dispatch: | ||
pull_request: | ||
types: | ||
- opened | ||
- synchronize | ||
- reopened | ||
push: | ||
branches: | ||
- main | ||
- release/v* | ||
paths-ignore: | ||
- '.github/**' | ||
- 'docs/**' | ||
- 'examples/**' | ||
- 'test/**' | ||
permissions: | ||
contents: read | ||
packages: write | ||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: false | ||
jobs: | ||
ci-go: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- name: Set up Go | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version-file: go.mod | ||
cache: false | ||
- name: Test Snapshot Release | ||
uses: goreleaser/goreleaser-action@v5 | ||
with: | ||
distribution: goreleaser | ||
version: latest | ||
args: release --config ./dev.goreleaser.yaml --clean --snapshot | ||
- name: Upload Test Release Assets | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: slack-notifier | ||
path: dist/* | ||
retention-days: 3 | ||
ci-docker: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: "Checkout source code at current commit" | ||
uses: actions/checkout@v4 | ||
- name: Build | ||
id: build | ||
uses: cloudposse/[email protected] | ||
with: | ||
registry: ghcr.io | ||
organization: "${{ github.event.repository.owner.login }}" | ||
repository: "${{ github.event.repository.name }}" | ||
login: "${{ github.actor }}" | ||
password: "${{ secrets.GITHUB_TOKEN }}" | ||
platforms: linux/amd64,linux/arm64 | ||
release: | ||
if: github.event_name == 'push' | ||
needs: [ci-go, ci-docker] | ||
uses: cloudposse/.github/.github/workflows/shared-go-auto-release.yml@main | ||
Check failure on line 79 in .github/workflows/feature-branch.yml GitHub Actions / Feature branchInvalid workflow file
|
||
with: | ||
publish: true | ||
format: binary | ||
secrets: inherit |