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
3 changes: 2 additions & 1 deletion .claude-plugin/marketplace.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
"name": "aiaddon",
"displayName": "AI Add-on Builder",
"description": "Describe what you want Claude to do, in your own words. AI Add-on Builder plans, builds, checks, and packages the skill or plugin for you, including internal tools for your team, and adds a Prompt Builder form that starts it. Works in Claude Code, Cowork, and claude.ai.",
"source": "./",
"source": "./adapters/claude",
"version": "0.3.0",
"category": "developer-tools"
}
]
Expand Down
59 changes: 6 additions & 53 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,16 +33,16 @@ jobs:
python-version: ${{ matrix.python }}
- name: Self-test the scripts
run: python dev/aiaddon-review/scripts/selftest.py
- name: Validate for the Claude plugin directory
run: python dev/aiaddon-review/scripts/validate_extension.py . --strict --target directory --require-meta author,company
- name: Validate the shipped plugin for the Claude plugin directory (adapters/claude)
run: python dev/aiaddon-review/scripts/validate_extension.py adapters/claude --strict --target directory --require-meta author,company
- name: Scan for plain-text secrets
run: python dev/aiaddon-review/scripts/scan_secrets.py .
- name: Screen docs for prompt injection
run: python dev/aiaddon-review/scripts/screen_text.py .
run: python dev/aiaddon-review/scripts/screen_text.py adapters/claude
- name: Check the router against its evals
run: python dev/aiaddon-review/scripts/route_check.py .
run: python dev/aiaddon-review/scripts/route_check.py adapters/claude
- name: Simulate skill triggers
run: python dev/aiaddon-review/scripts/simulate.py . triggers
run: python dev/aiaddon-review/scripts/simulate.py adapters/claude triggers
- name: Self-test as a non-root user
if: matrix.python == '3.13'
run: test "$(id -u)" != 0 && python dev/aiaddon-review/scripts/selftest.py | grep -q "PASS read-only source is staged, not written"
Expand All @@ -63,52 +63,5 @@ jobs:
run: python dev/aiaddon-review/scripts/scan_secrets.py . --history
- name: Scan built packages, when present (blocking)
run: |
python dev/aiaddon-package/scripts/build_skill_zips.py . --out "$RUNNER_TEMP/skill-zips"
python dev/aiaddon-package/scripts/build_skill_zips.py adapters/claude --out "$RUNNER_TEMP/skill-zips"
python dev/aiaddon-review/scripts/scan_secrets.py . --artifacts "$RUNNER_TEMP/skill-zips"

release-branch:
# Publishes the shipped plugin (repo minus maintainer-only files) to the `release` branch,
# which the Anthropic directory submission tracks. Same plugin content as main; no hooks,
# scripts or non-text files (directory policy for non-Verified organizations).
name: Update the release branch
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
needs: [checks, public-safety]
runs-on: ubuntu-24.04
timeout-minutes: 10
permissions:
contents: write
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
fetch-depth: 0
- uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
with:
python-version: "3.13"
- name: Build the shipped tree
run: |
git rm -r -q --cached --ignore-unmatch dev evals .github .claude IMPROVEMENTS.md .public-safety-allow assets/icon.svg
git clean -fdxq
rm -rf dev evals .github .claude IMPROVEMENTS.md .public-safety-allow assets/icon.svg
- name: Validate the shipped tree for the directory (blocking)
run: |
# The validator imports its neighbours (route check, public safety, screen), so extract the whole folder.
git archive HEAD dev/aiaddon-review/scripts | tar -x -C "$RUNNER_TEMP"
# The maintainer allowlist (public support address) is needed to validate but is never shipped:
# it is restored in the working tree only, the index (what gets pushed) stays without it.
git show HEAD:.public-safety-allow > .public-safety-allow
trap 'rm -f .public-safety-allow' EXIT
python "$RUNNER_TEMP/dev/aiaddon-review/scripts/validate_extension.py" . --strict --target directory --require-meta author,company
python "$RUNNER_TEMP/dev/aiaddon-review/scripts/scan_secrets.py" .
- name: Push the release branch
env:
GIT_AUTHOR_NAME: github-actions[bot]
GIT_AUTHOR_EMAIL: 41898282+github-actions[bot]@users.noreply.github.com
GIT_COMMITTER_NAME: github-actions[bot]
GIT_COMMITTER_EMAIL: 41898282+github-actions[bot]@users.noreply.github.com
run: |
# Fast-forward only (no force-push): a new commit on top of the current release branch.
tree=$(git write-tree)
parent=$(git rev-parse -q --verify origin/release || true)
if [ -n "$parent" ] && [ "$(git rev-parse "$parent^{tree}")" = "$tree" ]; then echo "release branch already up to date"; exit 0; fi
commit=$(git commit-tree "$tree" ${parent:+-p "$parent"} -m "release: shipped plugin from ${GITHUB_SHA::7}")
git push origin "$commit:refs/heads/release"
125 changes: 66 additions & 59 deletions .github/workflows/release-plugin.yml
Original file line number Diff line number Diff line change
@@ -1,90 +1,97 @@
name: Release plugin

# Builds aiaddon.plugin from the plugin.json version, plus one <skill>.zip per skill (skills/<name> -> dist/<name>.zip),
# and attaches them all to the GitHub release.
# Release (v* tag): https://github.com/syncwin/aiaddon/releases/latest/download/aiaddon.plugin
# Next (push to the next branch): rolling pre-release tagged "next",
# https://github.com/syncwin/aiaddon/releases/download/next/aiaddon.plugin
# The existing release.yml still attaches the signed, dotted-name package to v* releases.
# Builds aiaddon.plugin from adapters/claude (the shipped plugin) when a v* tag is pushed, plus one <skill>.zip per skill,
# the Prompt Builder prompt and SHA256SUMS, signs build provenance, and attaches everything to the GitHub release.
# One-click download: https://github.com/syncwin/aiaddon/releases/latest/download/aiaddon.plugin
# Verify a download: gh attestation verify aiaddon.plugin --repo syncwin/aiaddon
on:
push:
tags: ["v*"]
branches: [next]
workflow_dispatch:
inputs:
tag:
description: Existing release tag to rebuild, for example v0.3.0
required: true

permissions:
contents: write
contents: read

concurrency:
group: release-plugin-${{ github.ref }}
group: release-plugin-${{ inputs.tag || github.ref_name }}
cancel-in-progress: false

jobs:
release:
name: Build and attach aiaddon.plugin
name: Build, attest, attach aiaddon.plugin
runs-on: ubuntu-latest
timeout-minutes: 10
timeout-minutes: 15
permissions:
contents: write # create or update the release and attach files
id-token: write # sign the build provenance
attestations: write # store the provenance attestation
env:
NAME: "AI Add-on Builder"
ASSET: aiaddon.plugin
ROOT: .
ROOT: adapters/claude
TAG: ${{ inputs.tag || github.ref_name }}
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
ref: ${{ inputs.tag || github.ref }}
fetch-depth: 0 # full history for the secret scan
persist-credentials: false
- uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
with:
python-version: "3.13"
- name: Check the tag matches the plugin version
id: version
run: |
v=$(python -c "import json,os;print(json.load(open(os.environ['ROOT'] + '/.claude-plugin/plugin.json'))['version'])")
test "$TAG" = "v$v" || { echo "tag $TAG does not match plugin version $v"; exit 1; }
echo "version=$v" >> "$GITHUB_OUTPUT"
- name: Run every check
run: |
python dev/aiaddon-review/scripts/selftest.py
python dev/aiaddon-review/scripts/validate_extension.py "$ROOT" --strict --target directory --require-meta author,company
python dev/aiaddon-review/scripts/scan_secrets.py .
python dev/aiaddon-review/scripts/scan_secrets.py . --history
python dev/aiaddon-review/scripts/route_check.py "$ROOT"
python dev/aiaddon-review/scripts/screen_text.py "$ROOT"
- name: Build the package
id: build
run: |
python3 - <<'PY'
import json, os, zipfile
root, asset = os.environ["ROOT"], os.environ["ASSET"]
version = json.load(open(os.path.join(root, ".claude-plugin", "plugin.json"), encoding="utf-8"))["version"]
skip_dirs = {".git", ".github", ".claude", "tests", "node_modules", "__pycache__", "evals", "prompts", "dist", "dev"}
skip_files = {"IMPROVEMENTS.md"}
os.makedirs("dist", exist_ok=True)
out = os.path.join(os.getcwd(), "dist", asset)
if os.path.exists(out):
os.remove(out)
with zipfile.ZipFile(out, "w", zipfile.ZIP_DEFLATED) as z:
for d, dirs, files in os.walk(root):
dirs[:] = sorted(x for x in dirs if x not in skip_dirs)
for f in sorted(files):
if f in skip_files or f.endswith(".pyc"):
continue
p = os.path.join(d, f)
z.write(p, os.path.relpath(p, root).replace(os.sep, "/"))
with zipfile.ZipFile(out) as z:
assert ".claude-plugin/plugin.json" in z.namelist(), "plugin.json missing at zip root"
with open(os.environ.get("GITHUB_OUTPUT", os.devnull), "a") as g:
g.write("version=" + version + "\n")
print("built", out, "version", version)
# package_extension leaves out dev/, evals/, prompts/, .github/, .claude/, IMPROVEMENTS.md and .public-safety-allow.
python dev/aiaddon-package/scripts/package_extension.py "$ROOT" --format plugin --out dist --repo "$GITHUB_REPOSITORY" --force
python dev/aiaddon-package/scripts/build_skill_zips.py "$ROOT" --out dist
cd dist
mv -- "$(ls -- *.plugin | head -1)" "$ASSET"
rm -f -- *" install.md"
python - <<'PY'
import os, zipfile
names = zipfile.ZipFile(os.environ["ASSET"]).namelist()
text_ext = {".md", ".json", ".yaml", ".yml", ".txt", ".png", ".jpg", ".jpeg", ".gif", ".webp", ".ico"}
text_names = {"LICENSE", ".gitignore"}
assert ".claude-plugin/plugin.json" in names, "plugin.json missing at the package root"
bad = [n for n in names if os.path.splitext(n)[1].lower() not in text_ext and os.path.basename(n) not in text_names]
assert not bad, "files the directory refuses: " + ", ".join(bad)
assert not [n for n in names if n.split("/")[0] in ("hooks", "scripts", "dev", "evals", "prompts") or os.path.basename(n) in (".public-safety-allow", "IMPROVEMENTS.md")], "maintainer files or hooks in the package"
print("package ok:", len(names), "files")
PY
- name: Build one zip per skill
run: python3 dev/aiaddon-package/scripts/build_skill_zips.py . --out dist
sha256sum -- "$ASSET" ai-add-on-builder.json *.zip > SHA256SUMS
cat SHA256SUMS
- name: Scan the built packages for secrets and private data (blocking)
run: python3 dev/aiaddon-review/scripts/scan_secrets.py . --artifacts dist
- name: Check the tag matches the plugin version
if: github.ref_type == 'tag'
env:
VERSION: ${{ steps.build.outputs.version }}
run: test "$GITHUB_REF_NAME" = "v$VERSION" || { echo "tag $GITHUB_REF_NAME does not match plugin version $VERSION"; exit 1; }
- name: Attach to the version release
if: github.ref_type == 'tag'
run: python dev/aiaddon-review/scripts/scan_secrets.py . --artifacts dist
- uses: actions/attest-build-provenance@4d101475d8b20a2381f78447822ac1eab6504dd8 # v4.2.2
with:
subject-path: |
dist/${{ env.ASSET }}
dist/ai-add-on-builder.json
- name: Create or update the release
env:
GH_TOKEN: ${{ github.token }}
VERSION: ${{ steps.build.outputs.version }}
run: |
tag="v$VERSION"
if gh release view "$tag" >/dev/null 2>&1; then
gh release upload "$tag" "dist/$ASSET" dist/*.zip --clobber
cd dist
if gh release view "$TAG" >/dev/null 2>&1; then
gh release upload "$TAG" "$ASSET" ai-add-on-builder.json SHA256SUMS *.zip --clobber
else
gh release create "$tag" "dist/$ASSET" dist/*.zip --title "$NAME $tag" --generate-notes --target "$GITHUB_SHA" || gh release upload "$tag" "dist/$ASSET" dist/*.zip --clobber
gh release create "$TAG" "$ASSET" ai-add-on-builder.json SHA256SUMS *.zip --title "$NAME $TAG" --generate-notes --verify-tag
fi
- name: Update the rolling next pre-release
if: github.ref_type == 'branch'
env:
GH_TOKEN: ${{ github.token }}
VERSION: ${{ steps.build.outputs.version }}
run: |
gh release delete next --cleanup-tag --yes || true
gh release create next "dist/$ASSET" dist/*.zip --prerelease --target "$GITHUB_SHA" --title "$NAME next (v$VERSION)" --notes "Rolling pre-release built from the next branch at $GITHUB_SHA. Not for production; the stable package is on the latest v* release."
79 changes: 0 additions & 79 deletions .github/workflows/release.yml

This file was deleted.

8 changes: 8 additions & 0 deletions .public-safety-allow
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,11 @@ email:aiaddon/references/standards.md:support@syncwin.com
drive-path:AGENTS.md:A:\Automation
drive-path:AGENTS.md:D:\SyncWin
email:skills/*/references/standards.md:support@syncwin.com
# Single-branch layout: the shipped plugin sits in adapters/claude/, so the same public contact appears under that prefix (the scans also apply these without the prefix when run inside adapters/claude):
email:adapters/claude/.claude-plugin/plugin.json:support@syncwin.com
email:adapters/claude/PRIVACY.md:support@syncwin.com
email:adapters/claude/PUBLIC-SAFETY.md:support@syncwin.com
email:adapters/claude/README.md:support@syncwin.com
email:adapters/claude/SECURITY.md:support@syncwin.com
email:adapters/claude/skills/aiaddon/references/standards.md:support@syncwin.com
email:adapters/claude/skills/*/references/standards.md:support@syncwin.com
Loading
Loading