Skip to content
Merged
Show file tree
Hide file tree
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
120 changes: 0 additions & 120 deletions .github/workflows/build-native-packages.yml

This file was deleted.

66 changes: 45 additions & 21 deletions .github/workflows/publish-npm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,9 @@ jobs:
if-no-files-found: error
retention-days: 7

# Build goose binaries for all platforms
# Build goose CLI binaries for all platforms
build-goose-binaries:
name: Build goose (${{ matrix.platform }})
name: Build goose CLI (${{ matrix.platform }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
Expand All @@ -111,9 +111,10 @@ jobs:
- platform: linux-x64
os: ubuntu-latest
target: x86_64-unknown-linux-gnu
- platform: win32-x64
os: windows-latest
target: x86_64-pc-windows-msvc
# Temporarily disabled - Windows builds are slow (20+ min) without cache
# - platform: win32-x64
# os: windows-latest
# target: x86_64-pc-windows-msvc
Comment on lines +114 to +117
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Re-enable Windows build before publishing win32 binary pkg

In .github/workflows/publish-npm.yml, the Windows target is commented out, but the release job still publishes workspace packages and @aaif/goose continues to depend on @aaif/goose-binary-win32-x64 (ui/text/package.json). Since ui/goose-binary/.gitignore excludes */bin, CI checkouts do not contain bin/goose.exe, so the win32 package can be published without an executable, leaving Windows users with a broken bundled-server path.

Useful? React with 👍 / 👎.

outputs:
cache-key-base: ${{ steps.cache-key.outputs.key-base }}
steps:
Expand Down Expand Up @@ -164,7 +165,7 @@ jobs:
target/${{ matrix.target }}/release/goose${{ matrix.platform == 'win32-x64' && '.exe' || '' }}
key: ${{ steps.cache-key.outputs.key }}

- name: Build goose binary
- name: Build goose CLI binary
if: steps.binary-cache.outputs.cache-hit != 'true'
run: cargo build --release --target ${{ matrix.target }} --bin goose
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Include goose CLI crates in publish trigger paths

After this change the workflow builds --bin goose, but on.push.paths still only watches crates/goose-acp/** and ui/acp/**; as a result, pushes to main that modify crates/goose-cli/**, crates/goose/**, or other goose CLI dependencies will not trigger this publish pipeline, and npm native packages can be released with stale binaries. Please update the path filters (or remove them) so source changes for the goose binary always run this workflow.

Useful? React with 👍 / 👎.


Expand Down Expand Up @@ -227,7 +228,7 @@ jobs:
echo "Downloaded ACP schema:"
ls -lh crates/goose-acp/acp-*.json
echo ""
echo "Downloaded goose binaries:"
echo "Downloaded goose CLI binaries:"
ls -R goose-binaries/

- name: Install dependencies
Expand Down Expand Up @@ -259,7 +260,7 @@ jobs:
echo "### ACP Schema"
echo "✅ Generated and cached"
echo ""
echo "### Goose Binaries"
echo "### Goose CLI Binaries"
echo "✅ Built for all platforms:"
for dir in goose-binaries/goose-*; do
platform=$(basename "$dir" | sed 's/goose-//')
Expand All @@ -268,7 +269,7 @@ jobs:
echo ""
echo "### npm Packages"
echo "✅ @aaif/goose-acp"
echo "✅ @aaif/goose-text"
echo "✅ @aaif/goose (TUI)"
echo ""
} >> "$GITHUB_STEP_SUMMARY"

Expand All @@ -292,29 +293,52 @@ jobs:
echo "⚠️ Skipping actual npm publish (dry-run mode)"
echo ""
echo "To publish for real, run this workflow without dry-run enabled."
echo ""
echo "**Note:** Changesets will still run to verify functionality."
} >> "$GITHUB_STEP_SUMMARY"
fi

- name: Create Release Pull Request or Publish to npm
- name: Publish to npm
if: inputs.dry-run != true && github.ref == 'refs/heads/main'
id: changesets
uses: changesets/action@6a0a831ff30acef54f2c6aa1cbbc1096b066edaf # v1.7.0
with:
publish: pnpm run release
version: pnpm run version
commit: 'chore: version packages'
title: 'chore: version packages'
cwd: ui
run: |
cd ui
# Publish all packages in the workspace
pnpm publish -r --access public --no-git-checks
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Scope npm publish to intended packages

This replaces changesets-driven publishing with pnpm publish -r, which (per pnpm publish --help) publishes all workspace packages. In this repo, ui/pnpm-workspace.yaml includes desktop, so this step can attempt to publish ui/desktop (goose-app) alongside ACP/TUI/native packages, causing release failures or unintended npm publishes. The workflow should filter to the explicit release packages instead of publishing the entire workspace.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Filter publish to version-bumped packages

Running pnpm publish -r --access public --no-git-checks here attempts to publish every workspace package on each main-branch run, but this commit removed the changesets versioning step that previously prepared publishable versions. In practice that means unchanged package versions will be re-attempted and npm will reject already-published versions, so a release can fail before newly bumped packages are published; add a version-bump step (or publish filtering) so only packages with new versions are sent to npm.

Useful? React with 👍 / 👎.

env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }}
NPM_CONFIG_PROVENANCE: true

- name: Dry run - Show what would be published
if: inputs.dry-run == true || github.ref != 'refs/heads/main'
run: |
cd ui
echo "## 📦 Packages that would be published:" | tee -a "$GITHUB_STEP_SUMMARY"
echo "" | tee -a "$GITHUB_STEP_SUMMARY"

# List all publishable packages
for pkg in acp text goose-binary/*/; do
if [ -f "$pkg/package.json" ]; then
name=$(jq -r '.name' "$pkg/package.json")
version=$(jq -r '.version' "$pkg/package.json")
echo "- $name@$version" | tee -a "$GITHUB_STEP_SUMMARY"
fi
done

echo "" | tee -a "$GITHUB_STEP_SUMMARY"
echo "**Note:** This is a dry run. No packages were published." | tee -a "$GITHUB_STEP_SUMMARY"

- name: Publish summary
if: steps.changesets.outputs.published == 'true' && inputs.dry-run != true && github.ref == 'refs/heads/main'
if: inputs.dry-run != true && github.ref == 'refs/heads/main'
run: |
cd ui
{
echo "## 🚀 Published Packages"
echo ""
echo '${{ steps.changesets.outputs.publishedPackages }}' | jq -r '.[] | "- \(.name)@\(.version)"'
for pkg in acp text goose-binary/*/; do
if [ -f "$pkg/package.json" ]; then
name=$(jq -r '.name' "$pkg/package.json")
version=$(jq -r '.version' "$pkg/package.json")
echo "- $name@$version"
fi
done
} >> "$GITHUB_STEP_SUMMARY"
Loading
Loading