diff options
| author | Jesse Vincent <jesse@fsck.com> | 2026-10-07 18:51:41 -0700 |
|---|---|---|
| committer | Jesse Vincent <jesse@fsck.com> | 2026-10-07 18:51:41 -0700 |
| commit | 0d06b085e87a1c0ef8308d276ddbe822fc17f923 (patch) | |
| tree | d9cb97af8fda5f921cc38bb002232a3f8fef1c16 /scripts | |
| parent | 9e639188a1a8029926bda6e5d7edbf66ef3ac333 (diff) | |
feat(antigravity): native plugin manifest for the Antigravity Marketplace
Add .antigravity-plugin/plugin.json with the Marketplace fields
(displayName, logo, suggestedPrompts, version, author), a logo rendered
from the Superpowers mark by scripts/render-antigravity-logo.sh, and a
.version-bump.json entry. The Codex sync excludes the manifest and logo.
With the native manifest, agy installs Superpowers as an Antigravity
plugin. Before, `agy plugin install <repo>` fell back to importing the
repo as a Gemini CLI extension and rejected the copied Claude-format hooks
file on every session.
Superpowers bootstraps through skill discovery: agy lists each installed
skill's description, and using-superpowers' "Use when starting any
conversation" gets the model to load it. agy has no session-start hook
event; a rules/ file would also load in Cursor, which reads plugin rules
from the same repo root; a PreInvocation hook runs on every model call.
Verified on agy 1.3.1 (Gemini 3.8 Flash) across 15 clean sessions:
brainstorming or systematic-debugging loads before any code.
Diffstat (limited to 'scripts')
| -rwxr-xr-x | scripts/render-antigravity-logo.sh | 66 | ||||
| -rwxr-xr-x | scripts/sync-to-codex-plugin.sh | 4 |
2 files changed, 70 insertions, 0 deletions
diff --git a/scripts/render-antigravity-logo.sh b/scripts/render-antigravity-logo.sh new file mode 100755 index 0000000..82a5bd8 --- /dev/null +++ b/scripts/render-antigravity-logo.sh @@ -0,0 +1,66 @@ +#!/usr/bin/env bash +# +# Render the Antigravity Marketplace logo from assets/superpowers-small.svg. +# +# Usage: +# scripts/render-antigravity-logo.sh [--output PATH] +# +# Draws the Superpowers mark in near-black on a white rounded square with +# transparent corners, 512x512 PNG. Run it whenever superpowers-small.svg +# changes; tests/antigravity/test-logo.sh fails if the committed PNG is stale. +# Requires rsvg-convert (Homebrew: librsvg). +set -euo pipefail + +SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" +REPO_ROOT="$(cd "$SCRIPT_DIR/.." && pwd)" +SOURCE_SVG="$REPO_ROOT/assets/superpowers-small.svg" +OUTPUT="$REPO_ROOT/assets/antigravity-logo.png" + +usage() { + sed -n '2,11p' "$0" | sed 's/^# \{0,1\}//' +} + +die() { + echo "error: $*" >&2 + exit 1 +} + +while [[ $# -gt 0 ]]; do + case "$1" in + --output) + [[ $# -ge 2 ]] || die "--output needs a path" + OUTPUT="$2" + shift 2 + ;; + -h | --help) + usage + exit 0 + ;; + *) + usage >&2 + die "unknown argument: $1" + ;; + esac +done + +command -v rsvg-convert >/dev/null 2>&1 \ + || die "rsvg-convert is not on PATH (install librsvg, e.g. 'brew install librsvg')" +[[ -r "$SOURCE_SVG" ]] || die "source mark not readable: $SOURCE_SVG" + +# Everything inside the source <svg> element: the mark's paths and ellipse. +mark="$(sed -E 's/^.*<svg[^>]*>//; s#</svg>.*$##' "$SOURCE_SVG")" +[[ -n "$mark" ]] || die "could not extract the mark from $SOURCE_SVG" + +# The mark's bounding box is centered at (256,256) in its 512 viewBox and is +# 348 units wide; scale 0.905 makes it ~70% of the 450-unit rounded square. +composed="$(mktemp)" +trap 'rm -f "$composed"' EXIT +cat >"$composed" <<EOF +<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512" width="512" height="512"> + <rect x="31" y="31" width="450" height="450" rx="100" ry="100" fill="#ffffff"/> + <g fill="#1a1a1a" transform="translate(256 256) scale(0.905) translate(-256 -256)">$mark</g> +</svg> +EOF + +rsvg-convert -w 512 -h 512 "$composed" -o "$OUTPUT" +echo "wrote $OUTPUT" diff --git a/scripts/sync-to-codex-plugin.sh b/scripts/sync-to-codex-plugin.sh index 8ff283a..fc80ab2 100755 --- a/scripts/sync-to-codex-plugin.sh +++ b/scripts/sync-to-codex-plugin.sh @@ -44,6 +44,7 @@ DEST_REL="plugins/superpowers" # (.DS_Store is intentionally unanchored — Finder creates them everywhere.) EXCLUDES=( # Dotfiles and infra — top-level only + "/.antigravity-plugin/" "/.claude/" "/.claude-plugin/" "/.codex/" @@ -80,6 +81,9 @@ EXCLUDES=( "/scripts/" "/tests/" "/tmp/" + + # Other harnesses' assets + "/assets/antigravity-logo.png" ) # ============================================================================= |
