| name | publish |
| description | Publish a new release of iscsi-fuse. Bumps version, creates GitHub release, updates Homebrew formula, and installs locally via brew upgrade. |
| argument-hint | [version e.g. 0.2.0] |
| allowed-tools | Bash, Read, Edit, Glob, Grep |
You are publishing a new release of iscsi-fuse. Follow these steps precisely. If $ARGUMENTS is provided, use it as the new version number (e.g. 0.2.0). Otherwise, ask the user for the version.
Variables
- REPO_DIR:
/Users/peilinwu/project/iscsi
- TAP_DIR:
/Users/peilinwu/project/iscsi/homebrew-iscsi-fuse
- GITHUB_REPO:
dickwu/iscsi-fuse
- TAP_REPO:
dickwu/homebrew-iscsi-fuse
- NEW_VERSION:
$ARGUMENTS (strip any leading v)
Pre-flight checks
- Confirm the working directory is clean (
git status)
- Confirm we are on branch
main and up to date with origin
- Confirm macFUSE is installed (
brew list --cask macfuse)
Steps
1. Bump version in Cargo.toml
Edit Cargo.toml — change version = "X.Y.Z" to version = "$ARGUMENTS".
2. Run cargo check to validate
export PATH="$HOME/.cargo/bin:/opt/homebrew/bin:$PATH"
PKG_CONFIG_PATH=/usr/local/lib/pkgconfig cargo check 2>&1
If it fails, stop and report the error.
3. Format and lint
export PATH="$HOME/.cargo/bin:/opt/homebrew/bin:$PATH"
PKG_CONFIG_PATH=/usr/local/lib/pkgconfig cargo fmt --all
cargo clippy --all-targets -- -D warnings 2>&1
4. Commit the version bump
git add Cargo.toml Cargo.lock src/
git commit -m "chore: release v$ARGUMENTS
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>"
5. Tag and push
git tag "v$ARGUMENTS"
git push origin main
git push origin "v$ARGUMENTS"
6. Wait for GitHub Actions release workflow
sleep 5
RUN_ID=$(gh run list --repo dickwu/iscsi-fuse --workflow=release.yml --limit 1 --json databaseId --jq '.[0].databaseId')
gh run watch "$RUN_ID" --repo dickwu/iscsi-fuse
If the workflow fails, show the failure logs with gh run view --log-failed.
7. Get the release asset name and compute SHA256
ASSET=$(gh release view "v$ARGUMENTS" --repo dickwu/iscsi-fuse --json assets --jq '.assets[0].name')
mkdir -p /tmp/iscsi-release-new
gh release download "v$ARGUMENTS" --repo dickwu/iscsi-fuse --dir /tmp/iscsi-release-new
SHA256=$(shasum -a 256 "/tmp/iscsi-release-new/$ASSET" | awk '{print $1}')
echo "Asset: $ASSET"
echo "SHA256: $SHA256"
8. Update the Homebrew formula
In TAP_DIR/Formula/iscsi-fuse.rb:
- Update
version "X.Y.Z" to version "$ARGUMENTS"
- Update
sha256 "..." to the new SHA256
- Update the URL if the asset filename changed (arm64 vs universal)
Then commit and push:
cd TAP_DIR
git add Formula/iscsi-fuse.rb
git commit -m "Update iscsi-fuse to v$ARGUMENTS
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>"
git push origin main
9. Install locally via brew
brew untap dickwu/iscsi-fuse 2>/dev/null || true
brew tap dickwu/iscsi-fuse
brew upgrade iscsi-fuse 2>/dev/null || brew install iscsi-fuse
Verify:
iscsi-fuse --help
which iscsi-fuse
10. Report success
Print a summary:
- New version installed
- GitHub Release URL
- Homebrew tap URL
brew tap dickwu/iscsi-fuse && brew install iscsi-fuse command for users
Error handling
- If any step fails, stop immediately and report what went wrong
- If the release workflow fails, show
gh run view --log-failed
- If brew install fails, show the full error
- Do NOT continue past a failure — the user must decide how to proceed