* Reapply "test(install): add a regression suite for install.sh + CI on Linux and macOS (#772)" (#827)
This reverts commit 4bab3cf4a2.
* fix(install): refuse --path only for tools that would overwrite each other; re-land installer test suite (#772)
Re-lands the install.sh regression suite from #772 (reverted in #827) together
with the guard change that makes it pass, so CI goes green in one step.
Background. #825 made --path refuse more than one --tool, on #819's report that
several tools sharing one destination clobber each other. That was right in
spirit and over-broad in practice, and it was implemented without verifying
the premise. Measured by installing one agent with every tool into a sandbox
and comparing what landed:
<division>-<slug>.md (raw copy) claude-code, copilot
<slug>.md (converted) gemini-cli, opencode, qwen, zcode
agency-<slug>/SKILL.md antigravity, osaurus
Tools in the same group write identical filenames and silently overwrite each
other (qwen + gemini-cli lose a file while both print [OK]). Tools in different
groups coexist (claude-code + codex, claude-code + qwen). Every other tool's
output is distinct.
The guard now refuses --path only for a colliding pair, naming both tools and
the reason, and allows the rest. path_collision_group() holds the measured
table; re-measure if a converter's naming changes.
The suite's two-tool --path cases used claude-code + copilot, which collide:
the "installs exactly one agent" count of 1 was passing because copilot had
overwritten claude-code's identical file. They now use claude-code + codex and
assert that BOTH outputs survive, which a single count cannot show; a new case
asserts the colliding pair is refused. codex has no committed output, so those
cases convert (only the two raw-copiers work under --no-convert in a fresh
checkout).
Verified under bash 3.2 (the macOS CI leg): 29 passed, 0 failed, 1 xfail.
Guard spot-checked against all three measured groups plus a cross-group pair.
Suite, workflow and CONTRIBUTING note by @SergiorCode (#772). Refs #772#819#825#827.
Co-Authored-By: SergiorCode <SergiorCode@users.noreply.github.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* fix(install): auto-convert never fired in a fresh checkout — README.md read as generated output
ensure_converted decided a converted tool's output was present if its
integrations/<tool>/ directory contained any file. Every one of those
directories ships a committed README.md, so in a fresh checkout the check
always found a file, skipped convert.sh, and the installer then hard-failed
"integrations/<tool> missing. Run convert.sh first." — the exact flow #426's
auto-convert was added to prevent. This affected every converted tool; it was
masked locally by generated outputs left behind in the working tree, and
surfaced only when the test suite ran in a clean checkout.
Only files other than README.md now count as generated output. Verified in a
clean worktree under bash 3.2: the suite's serial-control case (claude-code +
codex into one --path) now auto-converts codex and both outputs land;
29 passed, 0 failed, 1 xfail.
Refs #426
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
---------
Co-authored-by: SergiorCode <SergiorCode@users.noreply.github.com>
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
* test(install): add a regression suite for install.sh + CI on Linux and macOS
install.sh is the largest script in the repo and has no tests. Every install
bug so far has been a silent one — agents copied to the wrong directory, a
path with a space split in two, a filter that installed everything — and the
only signal was a user noticing later.
scripts/test-install.sh pins the installer's observable contract:
* destinations: default $HOME/.claude/agents, --path override, tool env var
override, and --path winning over the env var
* selection: --division, --agent, --agents-file (comments/blank lines)
* --dry-run writes nothing; unknown --tool exits non-zero
* --link produces symlinks; a second run installs the same set, not dupes
* a destination containing spaces stays one directory
Expected counts are derived from divisions.json + lib.sh at runtime, so the
suite doesn't need updating when agents are added. Every case runs with HOME
pointed at a throwaway sandbox, so a broken default path can never write into
the real config. bash 3.2 + BSD userland, no new dependencies.
Verified it fails on the regressions it claims to catch: unquoting install_file
fails only the spaces case, neutering slug_allowed fails the four selection
cases, un-short-circuiting --dry-run fails the dry-run case, and ignoring the
env var in resolve_dest fails the env-override case.
CI runs it on ubuntu-latest and macos-latest (macOS ships bash 3.2, Linux
ships bash 5) plus bash -n over every script in scripts/.
* test(install): pin the parallel worker argument regression (#755)
Review feedback: the existing "paths with spaces" case selects a single tool,
so it stays on the serial path and never reaches the worker spawn where #755's
bug lives. Adds a case that does.
--tool claude-code,copilot --parallel --jobs 1 --agents-file <spaced path>
--path "<home>/My [Agents]/dest dir"
with a serial control immediately before it (same two tools, same spaced and
globbed --path, no --parallel) so a failure is attributable to the worker
hand-off rather than to the selection filter.
Marked xfail rather than a hard assertion: it fails on main today and passes
with #755 applied, and encoding a known-broken case as a hard failure would
turn CI red for reasons unrelated to whatever PR is being reviewed. xfail
never fails the suite; when the case starts passing it prints a note to
promote it to assert_eq (one-word edit). Measured on macOS bash 3.2.57:
main -> 25 passed / 1 xfail, #755 applied -> 26 passed / 0 failed, both
deterministic over repeated runs.
Note on --jobs 1: workers are still spawned through the same xargs/sh
hand-off, so argument propagation is exercised in full. Serializing them
keeps a second, unrelated defect out of this case — with two workers running
concurrently against one shared --path, the parent exits non-zero on ~3 runs
in 5 once the workers actually copy anything (one worker's cp fails with
ENOENT on the shared destination). That race is invisible on main only
because the workers currently install nothing at all; --jobs 1 or per-tool
destinations are clean. Reported in the PR discussion.
Two related drift traps, both from hand-typed numbers/lists that no guard
watches:
1. CONTRIBUTING had no "how to add a tool" checklist, and its wording
("all output is gitignored") implied gitignoring was automatic — so
tool contributors kept committing generated integrations/<tool>/ output.
2. The division set and agent/division counts were hardcoded in prose in
several places and had already gone stale (CONTRIBUTING said "16" and
omitted healthcare; EXECUTIVE-BRIEF said "9 divisions").
Changes:
- Add an "Adding a Tool Integration" checklist to CONTRIBUTING (discuss-first,
reuse an existing `format`, the ~5-file touch list incl. the required
.gitignore rule, run check-tools.sh). Harmonize the "committed build
output" policy line to point at it.
- De-hardcode the division list in CONTRIBUTING — defer to divisions.json.
- Stop scattering roster counts: strategy/EXECUTIVE-BRIEF ("9 divisions") and
check-agent-originality.sh ("184-agent library") drop the number entirely;
README keeps a showcase stat but softens "232 across 16" to "230+ across
every division" so it never becomes a lie as the roster grows.
Claude-Session: https://claude.ai/code/session_01WKnDRWM4izsB8WAXKszhsq
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Tooling: add Osaurus (Anthropic Agent-Skills SKILL.md format) as a conversion
and install target, wired into convert.sh (convert_osaurus + dispatch/valid/all/
parallel lists, --osaurus flag) and install.sh (detect/label/dest/install_osaurus
+ dispatch). Generated output lands in integrations/osaurus/agency-*/SKILL.md and
is gitignored like every other tool's output (regenerate via convert.sh osaurus).
Docs/guardrails — make the division contract discoverable, since it lived only
in scattered script comments and tripped up multiple contributors:
- CONTRIBUTING.md: complete the division list to all 16 (was missing academic/
gis/sales) and document that divisions.json is the source of truth (CI-checked
by check-divisions.sh), how to propose a new division, and that strategy/
(NEXUS playbooks) and integrations/ (generated output) are NOT divisions.
- install.sh: correct the stale "sync with convert.sh / lint-agents.sh" comment —
install.sh intentionally keeps strategy/ in AGENT_DIRS (filtered at scan time),
so it is deliberately NOT the same set as the other two.
- .gitignore: ignore integrations/osaurus/agency-*/ (the osaurus output was the
one tool whose generated files weren't excluded).
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Adds Codex as a conversion/install target: each agent → `~/.codex/agents/<slug>.toml` with the three required Codex fields (name, description, developer_instructions).
Validated: all 184 agents generate valid, parseable TOML (incl. 21k-char agents with embedded code blocks) via the PR's TOML basic-string escaper. Matches OpenAI's documented custom-agent schema.
Thanks @yunuskilicdev.
Adds scripts/check-agent-originality.sh, which flags new agents that
substantially duplicate an existing one. It compares each candidate
against the whole roster (and other files in the same change set) using
entity-neutralized 8-word shingle overlap, so a find-replace "re-skin"
that only swaps a country/platform name can't slip past review.
- CI: new "Check agent originality" step in lint-agents.yml runs it on
changed agent files; a >=40% match fails the build.
- Docs: CONTRIBUTING.md gains a self-run "before submitting" step, a
checklist item, and a "things we'll always close" bullet for re-skins.
Calibration: across the existing 184-agent library the worst same-pair
similarity is ~1.5% (median 0%), so the WARN >=20% / FAIL >=40% defaults
leave a wide margin against false positives.
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Adds finance/ to AGENT_DIRS in all 3 scripts, CI workflow trigger paths, CONTRIBUTING.md category list, and README.md division roster. Also fixes duplicate sales entry in lint-agents.sh.
Clarify what belongs in a PR vs. a Discussion — agent files are always
welcome, but tooling/architecture/bulk changes should start as a
Discussion first. Committed build output will always be closed.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Add convert_qwen() to scripts/convert.sh for generating Qwen SubAgent .md files
- Add install_qwen() to scripts/install.sh for installing to .qwen/agents/ (project-scoped)
- Add qwen detection, tool label, and install cases
- Update README.md with Qwen in supported tools table + usage section
- Add integrations/qwen/agents/ to .gitignore + create .gitkeep
- Add Qwen Code compatibility note to CONTRIBUTING.md
- Preserve tools: field in Qwen output when present in source agents
- Fix interactive installer to show dynamic [1-N] toggle range
- Update README roadmap checklist to include Qwen Code
Qwen SubAgents use minimal YAML frontmatter (name, description) with optional tools: field preserved from source. Body content passes through unchanged.
Tested with 120 agents — all convert and install successfully.
OpenClaw support:
- Add section-splitting convert_openclaw() to convert.sh that routes
## headers by keyword into SOUL.md (persona) vs AGENTS.md (operations)
and generates IDENTITY.md with emoji + vibe from frontmatter
- Add integrations/openclaw/ to .gitignore
Frontmatter additions (all 112 agents):
- Add emoji and vibe fields to every agent for OpenClaw IDENTITY.md
generation and future dashboard/catalog use
- Add services field to carousel-growth-engine (Gemini API, Upload-Post)
- Add emoji/vibe to 7 new paid-media agents from PR #83
Agent quality:
- Rewrite accounts-payable-agent to be vendor-agnostic (remove AgenticBTC
dependency, use generic payments.* interface)
Documentation:
- CONTRIBUTING.md: Add Persona/Operations section grouping guidance,
emoji/vibe/services frontmatter fields, external services editorial policy
- README.md: Add OpenClaw to supported tools, update agent count to 112,
reduce third-party OpenClaw repo mention to one-line attribution
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>