Skip to content

Fix setup-agents tmux command length limit #4

Fix setup-agents tmux command length limit

Fix setup-agents tmux command length limit #4

Workflow file for this run

name: Release
on:
push:
tags:
- 'v*'
workflow_dispatch:
concurrency:
group: release-${{ github.ref }}
cancel-in-progress: false
permissions:
contents: write
jobs:
goreleaser:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6
with:
go-version: '1.26'
- name: Install cross-compilation toolchains
run: |
sudo apt-get update
sudo apt-get install -y gcc-mingw-w64-x86-64 gcc-aarch64-linux-gnu
- name: Reject replace directives in go.mod
run: |
if grep -qE '^replace\s' go.mod; then
echo "ERROR: go.mod contains replace directives — aborting release."
echo "Replace directives break 'go install ...@latest'."
grep -n '^replace' go.mod
exit 1
fi
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@ec59f474b9834571250b370d4735c50f8e2d1e29 # v7
with:
distribution: goreleaser
version: '~> v2'
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
publish-npm:
runs-on: ubuntu-latest
needs: goreleaser
continue-on-error: true
permissions:
contents: read
steps:
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
- name: Set up Node.js
uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6
with:
node-version: '24'
registry-url: 'https://registry.npmjs.org'
- name: Update npm-package version from tag
run: |
VERSION=${GITHUB_REF#refs/tags/v}
cd npm-package
npm version "$VERSION" --no-git-tag-version
- name: Publish to npm
run: |
cd npm-package
npm publish --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}