Skip to content

Commit

Permalink
ci: push
Browse files Browse the repository at this point in the history
  • Loading branch information
caarlos0 committed Jan 12, 2025
1 parent 96a6660 commit 8aa2222
Showing 1 changed file with 42 additions and 0 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/release-new.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: goreleaser

on:
workflow_dispatch:
pull_request:
push:
tags:
- "*"

permissions:
contents: write
packages: write
issues: write
id-token: write

jobs:
goreleaser:
runs-on: ubuntu-latest
env:
flags: ""
steps:
- if: ${{ !startsWith(github.ref, 'refs/tags/v') }}
run: echo "flags=--snapshot" >> $GITHUB_ENV
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: mlugg/setup-zig@v1
- run: rustup default nightly
- run: cargo install --locked cargo-zigbuild
- run: cargo fetch --locked
- uses: goreleaser/goreleaser-action@v6
with:
# either 'goreleaser' (default) or 'goreleaser-pro'
distribution: goreleaser
# 'latest', 'nightly', or a semver
version: "~> v2"
args: release --clean ${{ env.flags }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# Your GoReleaser Pro key, if you are using the 'goreleaser-pro' distribution
# GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}
GH_PAT: ${{ secrets.GH_PAT }}

0 comments on commit 8aa2222

Please sign in to comment.