From 69c5351f695893d1b55e2a9cb9ad5a3730ae42d6 Mon Sep 17 00:00:00 2001 From: Paul Thurlow Date: Mon, 30 Mar 2026 13:11:38 -0700 Subject: [PATCH 1/3] fix release script execute command --- scripts/release.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/release.sh b/scripts/release.sh index 03ba222..4e5e63d 100755 --- a/scripts/release.sh +++ b/scripts/release.sh @@ -79,7 +79,7 @@ case "$COMMAND" in echo "" echo "→ Running cargo release (tagging release)..." - cargo release + cargo release --execute echo "" echo "✓ Release complete. Tag pushed and dist workflow triggered." From 70474a12722bb5a9040fa7026e3d0529e742e483 Mon Sep 17 00:00:00 2001 From: Paul Thurlow Date: Mon, 30 Mar 2026 13:32:43 -0700 Subject: [PATCH 2/3] fix formula and give github app repo control --- .github/workflows/publish-homebrew.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/publish-homebrew.yml b/.github/workflows/publish-homebrew.yml index 15e3a42..b2865b8 100644 --- a/.github/workflows/publish-homebrew.yml +++ b/.github/workflows/publish-homebrew.yml @@ -21,7 +21,7 @@ jobs: app-id: ${{ secrets.HOTDATA_AUTOMATION_APP_ID }} private-key: ${{ secrets.HOTDATA_AUTOMATION_PRIVATE_KEY }} owner: hotdata-dev - repositories: homebrew-tap + repositories: homebrew-tap,hotdata-cli - uses: actions/checkout@v6 with: @@ -50,9 +50,9 @@ jobs: brew update brew style --except-cops FormulaAudit/Homepage,FormulaAudit/Desc,FormulaAuditStrict --fix "Formula/${filename}" || true - # Add shell completions generation if not already present + # Add shell completions generation before the closing "end" of the install method if ! grep -q 'generate_completions_from_executable' "Formula/${filename}"; then - sed -i '/bin\.install "hotdata"/a\ generate_completions_from_executable(bin/"hotdata", "completions")' "Formula/${filename}" + sed -i '/^ end$/i\ generate_completions_from_executable(bin/"hotdata", "completions")' "Formula/${filename}" fi git add "Formula/${filename}" @@ -62,7 +62,7 @@ jobs: - name: Remove .rb from GitHub Release assets env: - GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GH_TOKEN: ${{ steps.app-token.outputs.token }} run: | TAG=$(echo "$PLAN" | jq -r '.announcement_tag') if [ -z "$TAG" ] || [ "$TAG" = "null" ]; then From 2f7b5e72247251280bd25da5b9de4bbb40132ca2 Mon Sep 17 00:00:00 2001 From: Paul Thurlow Date: Mon, 30 Mar 2026 13:40:42 -0700 Subject: [PATCH 3/3] add completions after last install command --- .github/workflows/publish-homebrew.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/publish-homebrew.yml b/.github/workflows/publish-homebrew.yml index b2865b8..e4c2ab3 100644 --- a/.github/workflows/publish-homebrew.yml +++ b/.github/workflows/publish-homebrew.yml @@ -50,9 +50,12 @@ jobs: brew update brew style --except-cops FormulaAudit/Homepage,FormulaAudit/Desc,FormulaAuditStrict --fix "Formula/${filename}" || true - # Add shell completions generation before the closing "end" of the install method + # Add shell completions generation after the last bin.install line if ! grep -q 'generate_completions_from_executable' "Formula/${filename}"; then - sed -i '/^ end$/i\ generate_completions_from_executable(bin/"hotdata", "completions")' "Formula/${filename}" + last_bin_install=$(grep -n 'bin\.install' "Formula/${filename}" | tail -1 | cut -d: -f1) + if [ -n "$last_bin_install" ]; then + sed -i "${last_bin_install}a\\ generate_completions_from_executable(bin/\"hotdata\", \"completions\")" "Formula/${filename}" + fi fi git add "Formula/${filename}"