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
2 changes: 1 addition & 1 deletion .claude-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "basecamp",
"version": "0.1.0",
"version": "dev",
"description": "Basecamp integration for Claude Code. Create todos, track work, link code to projects.",
"author": {
"name": "37signals",
Expand Down
1 change: 1 addition & 0 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ project_name: basecamp
before:
hooks:
- sh -c 'mkdir -p completions && go run ./cmd/basecamp completion bash > completions/basecamp.bash && go run ./cmd/basecamp completion zsh > completions/_basecamp && go run ./cmd/basecamp completion fish > completions/basecamp.fish'
- scripts/stamp-plugin-version.sh {{ .Version }}

builds:
- id: basecamp
Expand Down
16 changes: 16 additions & 0 deletions scripts/stamp-plugin-version.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/usr/bin/env bash
set -euo pipefail

if ! command -v jq >/dev/null 2>&1; then
echo "Error: jq is required but not found. Install with your package manager." >&2
exit 1
fi

# Stamps the CLI release version into .claude-plugin/plugin.json so that
# Claude Code can detect updates. Called by GoReleaser before the build.

VERSION="${1:?Usage: stamp-plugin-version.sh VERSION}"
PLUGIN_JSON=".claude-plugin/plugin.json"

jq --arg v "$VERSION" '.version = $v' "$PLUGIN_JSON" > "${PLUGIN_JSON}.tmp"
mv "${PLUGIN_JSON}.tmp" "$PLUGIN_JSON"
Loading