Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 4 additions & 51 deletions .github/workflows/release-assets.yml
Original file line number Diff line number Diff line change
@@ -1,70 +1,23 @@
name: Upload Release Assets
name: Update Release README Links

on:
release:
types: [published]
workflow_dispatch:
inputs:
tag:
description: 'Release tag to build and upload assets for (e.g. v1.0.0)'
description: 'Release tag to update README links for (e.g. v1.0.0)'
required: true

jobs:
build:
name: Build (${{ matrix.os }}/${{ matrix.arch }})
update-readme:
name: Update README release links
runs-on: ubuntu-latest
env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
strategy:
matrix:
os: [linux, darwin, windows]
arch: [amd64, arm64]
steps:
- uses: actions/checkout@v6
with:
ref: ${{ inputs.tag || github.event.release.tag_name }}
- name: Set up Go
uses: actions/setup-go@v6
with:
go-version: '1.24'
- name: Build
run: |
GOOS=${{ matrix.os }}
GOARCH=${{ matrix.arch }}
BINARY_NAME=aperiodic
if [ "$GOOS" = "windows" ]; then BINARY_NAME=aperiodic.exe; fi
mkdir -p dist
GOARCH=$GOARCH GOOS=$GOOS go build -o dist/aperiodic-$GOOS-$GOARCH${BINARY_NAME#aperiodic} ./cmd/aperiodic
- name: Upload artifact
uses: actions/upload-artifact@v6
with:
name: aperiodic-${{ matrix.os }}-${{ matrix.arch }}
path: dist/

upload:
name: Upload to Release
runs-on: ubuntu-latest
needs: build
env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
permissions:
contents: write
steps:
- name: Download all artifacts
uses: actions/download-artifact@v8
with:
path: artifacts
- name: Prepare assets
run: |
mkdir -p release
cp artifacts/aperiodic-*/* release/
- name: Upload assets to release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ inputs.tag || github.event.release.tag_name }}
files: release/*
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Check out default branch
uses: actions/checkout@v6
with:
Expand Down