feat(factorydroid): native commands, subagents, and skills with global scope + hooks.json - #1797
Merged
Merged
Conversation
…global scope and move hooks to hooks.json Factory Droid has matured upstream: custom commands, subagents (custom droids), and skills are now native (not simulated), support a global ~/.factory/ scope with richer frontmatter, and the hooks config path standardized to hooks.json. - Commands: native Markdown in .factory/commands/ (project) and ~/.factory/commands/ (global). Frontmatter description/argument-hint pass through; allowed-tools reserved/optional. - Subagents (custom droids): native .md in .factory/droids/ with name/description plus model/reasoningEffort/tools/mcpServers passed through via the factorydroid rulesync section. - Skills: native .factory/skills/<name>/SKILL.md with name/description plus user-invocable/disable-model-invocation passthrough. - Hooks: primary path is now .factory/hooks.json (project + global), with .factory/settings.json hooks key kept as a read-time fallback. The dedicated hooks.json is now deletable. - Remove the now-obsolete simulated additionalConventions wiring for factorydroid in rules-processor. - Update gitignore (hooks.json), docs matrix, and the Tool x Feature e2e happy-path matrices accordingly. Closes #1790 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Owner
Author
|
@dyoshikawa Thank you! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Factory Droid (
factorydroid) has matured upstream: custom commands, subagents (custom droids), and skills are now native (no longer simulated), support a global~/.factory/scope with richer frontmatter, and the hooks config path standardized tohooks.json. This PR folds all of these into one follow-up, as requested by the maintainer.Closes #1790
Issue: #1790
Changes
Commands → native + global +
argument-hintFactorydroidCommandis now a nativeToolCommand(Markdown), mirroringClaudecodeCommand..factory/commands/(project) and~/.factory/commands/(global).descriptionandargument-hintpass through;allowed-toolsis reserved/optional (passed through vialooseObject). Extra fields round-trip through thefactorydroidrulesync section.isSimulated: false,supportsGlobal: true.Subagents (custom droids) → native + global + rich frontmatter
FactorydroidSubagentis now a nativeToolSubagent. Paths:.factory/droids/(project) and~/.factory/droids/(global).name,descriptionare preserved;model,reasoningEffort,tools,mcpServers(and any extra fields) round-trip through thefactorydroidrulesync section (junie/geminicli pattern).supportsSimulated: false,supportsGlobal: true.Skills → native + global + frontmatter passthrough
FactorydroidSkillis now a nativeToolSkill(mirrorsGeminiCliSkill). Path:.factory/skills/<name>/SKILL.md(project) + global under home.name,description,user-invocable,disable-model-invocationpass through.supportsProject: true,supportsSimulated: false,supportsGlobal: true.Hooks →
hooks.json(+ global) withsettings.jsonread fallbackgetSettablePathsnow returns.factory/hooks.jsonfor both project and global.fromFilereads.factory/hooks.jsonfirst; if absent, falls back to thehookskey in the legacy.factory/settings.json(back-compat, matching Droid's own fallback). Generation writeshooks.jsononly.hooks.jsonis now a dedicated hooks file, it is deletable (consistent with devin/goose). The previousisDeletable() === falseoverride was removed.Conventions / gitignore / docs
additionalConventionswiring for factorydroid inrules-processor.ts(commands/subagents/skills are native now).gitignore-entries.ts: factorydroid hooks entry changed from**/.factory/settings.json(general) to**/.factory/hooks.json(hooks). Regenerated project.gitignoreand cleaned up a stale stray**/.factory/settings.jsonline.docs/reference/supported-tools.md): factorydroid commands/subagents/skills changed from🎮to✅ 🌏.skills/rulesync/supported-tools.mdauto-synced. README already showed✅and needs no change.Tests
factorydroid-hooks.test.tsfor thehooks.jsonpath, the settings.json read-fallback, andisDeletable === true..factory/hooks.json.Verification
pnpm cicheckis fully green (format, oxlint 0 warnings, typecheck, 6095 unit tests, skill-docs sync, cspell, secretlint). The e2e specs (run viapnpm test:e2e) also pass (251 tests across the four affected specs).🤖 Generated with Claude Code