Release #64
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: Release | |
on: | |
push: | |
tags: | |
- '**' | |
workflow_dispatch: | |
permissions: | |
contents: write | |
packages: write | |
jobs: | |
goreleaser: | |
runs-on: ubuntu-latest | |
if: "startsWith(github.ref, 'refs/tags/v')" | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- run: git fetch --force --tags | |
- uses: actions/setup-go@v4 | |
with: | |
go-version: '1.21.x' | |
cache: true | |
- uses: goto-bus-stop/setup-zig@v2 | |
with: | |
zig-version: '0.11.0' | |
cache: true | |
- uses: goreleaser/goreleaser-action@v4 | |
with: | |
distribution: goreleaser | |
version: latest | |
args: release --clean | |
env: | |
# Custom secret here since we need to access to j178/homebrew-tap and j178/scoop-bucket repo. | |
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} | |
DISCORD_WEBHOOK_ID: ${{ secrets.DISCORD_WEBHOOK_ID }} | |
DISCORD_WEBHOOK_TOKEN: ${{ secrets.DISCORD_WEBHOOK_TOKEN }} | |
release_pypi: | |
runs-on: ubuntu-latest | |
if: "startsWith(github.ref, 'refs/tags/testutils/python/v')" | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.11' | |
- name: Install deps | |
run: | |
python -m pip install build twine | |
- run: | | |
python -m build | |
twine upload dist/* | |
working-directory: testutils/python | |
env: | |
TWINE_USERNAME: __token__ | |
TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }} | |
release_cargo: | |
runs-on: ubuntu-latest | |
if: "startsWith(github.ref, 'refs/tags/testutils/rust/v')" | |
steps: | |
- uses: actions/checkout@v3 | |
- run: cargo publish | |
working-directory: testutils/rust | |
env: | |
RUST_BACKTRACE: 1 | |
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }} |