Skip to content

Instantly share code, notes, and snippets.

@dantman
Created September 6, 2026 01:30
Show Gist options
  • Select an option

  • Save dantman/555b1e2d53591d412545e9cafeae7114 to your computer and use it in GitHub Desktop.

Select an option

Save dantman/555b1e2d53591d412545e9cafeae7114 to your computer and use it in GitHub Desktop.
Pasteable bash one-shot to temporarily add `./pinact` to a project (e.g. one in a devcontainer) you want to pin GitHub actions in
(
set -e
version="$(gh release view --repo suzuki-shunsuke/pinact --json tagName -q .tagName)"
asset="$(echo "pinact_$(uname -s | tr '[:upper:]' '[:lower:]')_$(uname -m | sed 's/x86_64/amd64/;s/aarch64/arm64/')".tar.gz)"
gh release download -R suzuki-shunsuke/pinact "$version" -p "$asset"
gh attestation verify "$asset" \
-R suzuki-shunsuke/pinact \
--signer-workflow suzuki-shunsuke/go-release-workflow/.github/workflows/release.yaml
tar -xzf "$asset" -C . "pinact"
chmod +x ./pinact
rm "$asset"
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment