compound-engineering-pi 0.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +124 -0
- package/bin/compound-engineering-pi +12 -0
- package/bin/compound-plugin +12 -0
- package/compound-engineering-pi +12 -0
- package/compound-plugin +5 -0
- package/docs/pi.md +152 -0
- package/extensions/compound-engineering-compat.ts +452 -0
- package/package.json +84 -0
- package/pi-resources/compound-engineering/mcporter.json +7 -0
- package/plugins/coding-tutor/.claude-plugin/plugin.json +9 -0
- package/plugins/coding-tutor/README.md +37 -0
- package/plugins/coding-tutor/commands/quiz-me.md +1 -0
- package/plugins/coding-tutor/commands/sync-tutorials.md +25 -0
- package/plugins/coding-tutor/commands/teach-me.md +1 -0
- package/plugins/coding-tutor/skills/coding-tutor/SKILL.md +214 -0
- package/plugins/coding-tutor/skills/coding-tutor/scripts/create_tutorial.py +207 -0
- package/plugins/coding-tutor/skills/coding-tutor/scripts/index_tutorials.py +193 -0
- package/plugins/coding-tutor/skills/coding-tutor/scripts/quiz_priority.py +190 -0
- package/plugins/coding-tutor/skills/coding-tutor/scripts/setup_tutorials.py +118 -0
- package/plugins/compound-engineering/.claude-plugin/plugin.json +33 -0
- package/plugins/compound-engineering/CHANGELOG.md +457 -0
- package/plugins/compound-engineering/CLAUDE.md +89 -0
- package/plugins/compound-engineering/LICENSE +21 -0
- package/plugins/compound-engineering/README.md +232 -0
- package/plugins/compound-engineering/agents/design/design-implementation-reviewer.md +109 -0
- package/plugins/compound-engineering/agents/design/design-iterator.md +224 -0
- package/plugins/compound-engineering/agents/design/figma-design-sync.md +190 -0
- package/plugins/compound-engineering/agents/docs/ankane-readme-writer.md +65 -0
- package/plugins/compound-engineering/agents/research/best-practices-researcher.md +126 -0
- package/plugins/compound-engineering/agents/research/framework-docs-researcher.md +106 -0
- package/plugins/compound-engineering/agents/research/git-history-analyzer.md +59 -0
- package/plugins/compound-engineering/agents/research/learnings-researcher.md +264 -0
- package/plugins/compound-engineering/agents/research/repo-research-analyst.md +135 -0
- package/plugins/compound-engineering/agents/review/agent-native-reviewer.md +261 -0
- package/plugins/compound-engineering/agents/review/architecture-strategist.md +67 -0
- package/plugins/compound-engineering/agents/review/code-simplicity-reviewer.md +101 -0
- package/plugins/compound-engineering/agents/review/data-integrity-guardian.md +85 -0
- package/plugins/compound-engineering/agents/review/data-migration-expert.md +112 -0
- package/plugins/compound-engineering/agents/review/deployment-verification-agent.md +174 -0
- package/plugins/compound-engineering/agents/review/dhh-rails-reviewer.md +66 -0
- package/plugins/compound-engineering/agents/review/julik-frontend-races-reviewer.md +221 -0
- package/plugins/compound-engineering/agents/review/kieran-python-reviewer.md +133 -0
- package/plugins/compound-engineering/agents/review/kieran-rails-reviewer.md +115 -0
- package/plugins/compound-engineering/agents/review/kieran-typescript-reviewer.md +124 -0
- package/plugins/compound-engineering/agents/review/pattern-recognition-specialist.md +72 -0
- package/plugins/compound-engineering/agents/review/performance-oracle.md +137 -0
- package/plugins/compound-engineering/agents/review/schema-drift-detector.md +154 -0
- package/plugins/compound-engineering/agents/review/security-sentinel.md +114 -0
- package/plugins/compound-engineering/agents/workflow/bug-reproduction-validator.md +82 -0
- package/plugins/compound-engineering/agents/workflow/every-style-editor.md +64 -0
- package/plugins/compound-engineering/agents/workflow/lint.md +16 -0
- package/plugins/compound-engineering/agents/workflow/pr-comment-resolver.md +84 -0
- package/plugins/compound-engineering/agents/workflow/spec-flow-analyzer.md +134 -0
- package/plugins/compound-engineering/commands/agent-native-audit.md +278 -0
- package/plugins/compound-engineering/commands/changelog.md +138 -0
- package/plugins/compound-engineering/commands/create-agent-skill.md +9 -0
- package/plugins/compound-engineering/commands/deepen-plan.md +546 -0
- package/plugins/compound-engineering/commands/deploy-docs.md +113 -0
- package/plugins/compound-engineering/commands/feature-video.md +342 -0
- package/plugins/compound-engineering/commands/generate_command.md +163 -0
- package/plugins/compound-engineering/commands/heal-skill.md +143 -0
- package/plugins/compound-engineering/commands/lfg.md +20 -0
- package/plugins/compound-engineering/commands/release-docs.md +212 -0
- package/plugins/compound-engineering/commands/report-bug.md +151 -0
- package/plugins/compound-engineering/commands/reproduce-bug.md +100 -0
- package/plugins/compound-engineering/commands/resolve_parallel.md +35 -0
- package/plugins/compound-engineering/commands/resolve_todo_parallel.md +37 -0
- package/plugins/compound-engineering/commands/slfg.md +32 -0
- package/plugins/compound-engineering/commands/technical_review.md +8 -0
- package/plugins/compound-engineering/commands/test-browser.md +339 -0
- package/plugins/compound-engineering/commands/test-xcode.md +332 -0
- package/plugins/compound-engineering/commands/triage.md +311 -0
- package/plugins/compound-engineering/commands/workflows/brainstorm.md +124 -0
- package/plugins/compound-engineering/commands/workflows/compound.md +239 -0
- package/plugins/compound-engineering/commands/workflows/plan.md +551 -0
- package/plugins/compound-engineering/commands/workflows/review.md +526 -0
- package/plugins/compound-engineering/commands/workflows/work.md +433 -0
- package/plugins/compound-engineering/skills/agent-browser/SKILL.md +223 -0
- package/plugins/compound-engineering/skills/agent-native-architecture/SKILL.md +435 -0
- package/plugins/compound-engineering/skills/agent-native-architecture/references/action-parity-discipline.md +409 -0
- package/plugins/compound-engineering/skills/agent-native-architecture/references/agent-execution-patterns.md +467 -0
- package/plugins/compound-engineering/skills/agent-native-architecture/references/agent-native-testing.md +582 -0
- package/plugins/compound-engineering/skills/agent-native-architecture/references/architecture-patterns.md +478 -0
- package/plugins/compound-engineering/skills/agent-native-architecture/references/dynamic-context-injection.md +338 -0
- package/plugins/compound-engineering/skills/agent-native-architecture/references/files-universal-interface.md +301 -0
- package/plugins/compound-engineering/skills/agent-native-architecture/references/from-primitives-to-domain-tools.md +359 -0
- package/plugins/compound-engineering/skills/agent-native-architecture/references/mcp-tool-design.md +506 -0
- package/plugins/compound-engineering/skills/agent-native-architecture/references/mobile-patterns.md +871 -0
- package/plugins/compound-engineering/skills/agent-native-architecture/references/product-implications.md +443 -0
- package/plugins/compound-engineering/skills/agent-native-architecture/references/refactoring-to-prompt-native.md +317 -0
- package/plugins/compound-engineering/skills/agent-native-architecture/references/self-modification.md +269 -0
- package/plugins/compound-engineering/skills/agent-native-architecture/references/shared-workspace-architecture.md +680 -0
- package/plugins/compound-engineering/skills/agent-native-architecture/references/system-prompt-design.md +250 -0
- package/plugins/compound-engineering/skills/andrew-kane-gem-writer/SKILL.md +184 -0
- package/plugins/compound-engineering/skills/andrew-kane-gem-writer/references/database-adapters.md +231 -0
- package/plugins/compound-engineering/skills/andrew-kane-gem-writer/references/module-organization.md +121 -0
- package/plugins/compound-engineering/skills/andrew-kane-gem-writer/references/rails-integration.md +183 -0
- package/plugins/compound-engineering/skills/andrew-kane-gem-writer/references/resources.md +119 -0
- package/plugins/compound-engineering/skills/andrew-kane-gem-writer/references/testing-patterns.md +261 -0
- package/plugins/compound-engineering/skills/brainstorming/SKILL.md +190 -0
- package/plugins/compound-engineering/skills/compound-docs/SKILL.md +511 -0
- package/plugins/compound-engineering/skills/compound-docs/assets/critical-pattern-template.md +34 -0
- package/plugins/compound-engineering/skills/compound-docs/assets/resolution-template.md +93 -0
- package/plugins/compound-engineering/skills/compound-docs/references/yaml-schema.md +65 -0
- package/plugins/compound-engineering/skills/compound-docs/schema.yaml +176 -0
- package/plugins/compound-engineering/skills/create-agent-skills/SKILL.md +275 -0
- package/plugins/compound-engineering/skills/create-agent-skills/references/api-security.md +226 -0
- package/plugins/compound-engineering/skills/create-agent-skills/references/be-clear-and-direct.md +531 -0
- package/plugins/compound-engineering/skills/create-agent-skills/references/best-practices.md +404 -0
- package/plugins/compound-engineering/skills/create-agent-skills/references/common-patterns.md +595 -0
- package/plugins/compound-engineering/skills/create-agent-skills/references/core-principles.md +437 -0
- package/plugins/compound-engineering/skills/create-agent-skills/references/executable-code.md +175 -0
- package/plugins/compound-engineering/skills/create-agent-skills/references/iteration-and-testing.md +474 -0
- package/plugins/compound-engineering/skills/create-agent-skills/references/official-spec.md +134 -0
- package/plugins/compound-engineering/skills/create-agent-skills/references/recommended-structure.md +168 -0
- package/plugins/compound-engineering/skills/create-agent-skills/references/skill-structure.md +152 -0
- package/plugins/compound-engineering/skills/create-agent-skills/references/using-scripts.md +113 -0
- package/plugins/compound-engineering/skills/create-agent-skills/references/using-templates.md +112 -0
- package/plugins/compound-engineering/skills/create-agent-skills/references/workflows-and-validation.md +510 -0
- package/plugins/compound-engineering/skills/create-agent-skills/templates/router-skill.md +73 -0
- package/plugins/compound-engineering/skills/create-agent-skills/templates/simple-skill.md +33 -0
- package/plugins/compound-engineering/skills/create-agent-skills/workflows/add-reference.md +96 -0
- package/plugins/compound-engineering/skills/create-agent-skills/workflows/add-script.md +93 -0
- package/plugins/compound-engineering/skills/create-agent-skills/workflows/add-template.md +74 -0
- package/plugins/compound-engineering/skills/create-agent-skills/workflows/add-workflow.md +120 -0
- package/plugins/compound-engineering/skills/create-agent-skills/workflows/audit-skill.md +138 -0
- package/plugins/compound-engineering/skills/create-agent-skills/workflows/create-domain-expertise-skill.md +605 -0
- package/plugins/compound-engineering/skills/create-agent-skills/workflows/create-new-skill.md +191 -0
- package/plugins/compound-engineering/skills/create-agent-skills/workflows/get-guidance.md +121 -0
- package/plugins/compound-engineering/skills/create-agent-skills/workflows/upgrade-to-router.md +161 -0
- package/plugins/compound-engineering/skills/create-agent-skills/workflows/verify-skill.md +204 -0
- package/plugins/compound-engineering/skills/dhh-rails-style/SKILL.md +185 -0
- package/plugins/compound-engineering/skills/dhh-rails-style/references/architecture.md +653 -0
- package/plugins/compound-engineering/skills/dhh-rails-style/references/controllers.md +303 -0
- package/plugins/compound-engineering/skills/dhh-rails-style/references/frontend.md +510 -0
- package/plugins/compound-engineering/skills/dhh-rails-style/references/gems.md +266 -0
- package/plugins/compound-engineering/skills/dhh-rails-style/references/models.md +359 -0
- package/plugins/compound-engineering/skills/dhh-rails-style/references/testing.md +338 -0
- package/plugins/compound-engineering/skills/document-review/SKILL.md +87 -0
- package/plugins/compound-engineering/skills/dspy-ruby/SKILL.md +737 -0
- package/plugins/compound-engineering/skills/dspy-ruby/assets/config-template.rb +187 -0
- package/plugins/compound-engineering/skills/dspy-ruby/assets/module-template.rb +300 -0
- package/plugins/compound-engineering/skills/dspy-ruby/assets/signature-template.rb +221 -0
- package/plugins/compound-engineering/skills/dspy-ruby/references/core-concepts.md +674 -0
- package/plugins/compound-engineering/skills/dspy-ruby/references/observability.md +366 -0
- package/plugins/compound-engineering/skills/dspy-ruby/references/optimization.md +603 -0
- package/plugins/compound-engineering/skills/dspy-ruby/references/providers.md +418 -0
- package/plugins/compound-engineering/skills/dspy-ruby/references/toolsets.md +502 -0
- package/plugins/compound-engineering/skills/every-style-editor/SKILL.md +134 -0
- package/plugins/compound-engineering/skills/every-style-editor/references/EVERY_WRITE_STYLE.md +529 -0
- package/plugins/compound-engineering/skills/file-todos/SKILL.md +252 -0
- package/plugins/compound-engineering/skills/file-todos/assets/todo-template.md +155 -0
- package/plugins/compound-engineering/skills/frontend-design/SKILL.md +42 -0
- package/plugins/compound-engineering/skills/gemini-imagegen/SKILL.md +237 -0
- package/plugins/compound-engineering/skills/gemini-imagegen/requirements.txt +2 -0
- package/plugins/compound-engineering/skills/gemini-imagegen/scripts/compose_images.py +157 -0
- package/plugins/compound-engineering/skills/gemini-imagegen/scripts/edit_image.py +144 -0
- package/plugins/compound-engineering/skills/gemini-imagegen/scripts/gemini_images.py +263 -0
- package/plugins/compound-engineering/skills/gemini-imagegen/scripts/generate_image.py +133 -0
- package/plugins/compound-engineering/skills/gemini-imagegen/scripts/multi_turn_chat.py +216 -0
- package/plugins/compound-engineering/skills/git-worktree/SKILL.md +302 -0
- package/plugins/compound-engineering/skills/git-worktree/scripts/worktree-manager.sh +337 -0
- package/plugins/compound-engineering/skills/orchestrating-swarms/SKILL.md +1718 -0
- package/plugins/compound-engineering/skills/rclone/SKILL.md +150 -0
- package/plugins/compound-engineering/skills/rclone/scripts/check_setup.sh +60 -0
- package/plugins/compound-engineering/skills/resolve-pr-parallel/SKILL.md +89 -0
- package/plugins/compound-engineering/skills/resolve-pr-parallel/scripts/get-pr-comments +68 -0
- package/plugins/compound-engineering/skills/resolve-pr-parallel/scripts/resolve-pr-thread +23 -0
- package/plugins/compound-engineering/skills/skill-creator/SKILL.md +210 -0
- package/plugins/compound-engineering/skills/skill-creator/scripts/init_skill.py +303 -0
- package/plugins/compound-engineering/skills/skill-creator/scripts/package_skill.py +110 -0
- package/plugins/compound-engineering/skills/skill-creator/scripts/quick_validate.py +65 -0
- package/prompts/deepen-plan.md +549 -0
- package/prompts/feature-video.md +341 -0
- package/prompts/resolve_todo_parallel.md +36 -0
- package/prompts/test-browser.md +342 -0
- package/prompts/workflows-brainstorm.md +123 -0
- package/prompts/workflows-compound.md +238 -0
- package/prompts/workflows-plan.md +550 -0
- package/prompts/workflows-review.md +529 -0
- package/prompts/workflows-work.md +432 -0
- package/skills/agent-browser/SKILL.md +223 -0
- package/skills/agent-native-architecture/SKILL.md +435 -0
- package/skills/agent-native-architecture/references/action-parity-discipline.md +409 -0
- package/skills/agent-native-architecture/references/agent-execution-patterns.md +467 -0
- package/skills/agent-native-architecture/references/agent-native-testing.md +582 -0
- package/skills/agent-native-architecture/references/architecture-patterns.md +478 -0
- package/skills/agent-native-architecture/references/dynamic-context-injection.md +338 -0
- package/skills/agent-native-architecture/references/files-universal-interface.md +301 -0
- package/skills/agent-native-architecture/references/from-primitives-to-domain-tools.md +359 -0
- package/skills/agent-native-architecture/references/mcp-tool-design.md +506 -0
- package/skills/agent-native-architecture/references/mobile-patterns.md +871 -0
- package/skills/agent-native-architecture/references/product-implications.md +443 -0
- package/skills/agent-native-architecture/references/refactoring-to-prompt-native.md +317 -0
- package/skills/agent-native-architecture/references/self-modification.md +269 -0
- package/skills/agent-native-architecture/references/shared-workspace-architecture.md +680 -0
- package/skills/agent-native-architecture/references/system-prompt-design.md +250 -0
- package/skills/agent-native-reviewer/SKILL.md +260 -0
- package/skills/andrew-kane-gem-writer/SKILL.md +184 -0
- package/skills/andrew-kane-gem-writer/references/database-adapters.md +231 -0
- package/skills/andrew-kane-gem-writer/references/module-organization.md +121 -0
- package/skills/andrew-kane-gem-writer/references/rails-integration.md +183 -0
- package/skills/andrew-kane-gem-writer/references/resources.md +119 -0
- package/skills/andrew-kane-gem-writer/references/testing-patterns.md +261 -0
- package/skills/ankane-readme-writer/SKILL.md +63 -0
- package/skills/architecture-strategist/SKILL.md +66 -0
- package/skills/best-practices-researcher/SKILL.md +125 -0
- package/skills/brainstorming/SKILL.md +190 -0
- package/skills/bug-reproduction-validator/SKILL.md +81 -0
- package/skills/code-simplicity-reviewer/SKILL.md +100 -0
- package/skills/compound-docs/SKILL.md +511 -0
- package/skills/compound-docs/assets/critical-pattern-template.md +34 -0
- package/skills/compound-docs/assets/resolution-template.md +93 -0
- package/skills/compound-docs/references/yaml-schema.md +65 -0
- package/skills/compound-docs/schema.yaml +176 -0
- package/skills/create-agent-skills/SKILL.md +275 -0
- package/skills/create-agent-skills/references/api-security.md +226 -0
- package/skills/create-agent-skills/references/be-clear-and-direct.md +531 -0
- package/skills/create-agent-skills/references/best-practices.md +404 -0
- package/skills/create-agent-skills/references/common-patterns.md +595 -0
- package/skills/create-agent-skills/references/core-principles.md +437 -0
- package/skills/create-agent-skills/references/executable-code.md +175 -0
- package/skills/create-agent-skills/references/iteration-and-testing.md +474 -0
- package/skills/create-agent-skills/references/official-spec.md +134 -0
- package/skills/create-agent-skills/references/recommended-structure.md +168 -0
- package/skills/create-agent-skills/references/skill-structure.md +152 -0
- package/skills/create-agent-skills/references/using-scripts.md +113 -0
- package/skills/create-agent-skills/references/using-templates.md +112 -0
- package/skills/create-agent-skills/references/workflows-and-validation.md +510 -0
- package/skills/create-agent-skills/templates/router-skill.md +73 -0
- package/skills/create-agent-skills/templates/simple-skill.md +33 -0
- package/skills/create-agent-skills/workflows/add-reference.md +96 -0
- package/skills/create-agent-skills/workflows/add-script.md +93 -0
- package/skills/create-agent-skills/workflows/add-template.md +74 -0
- package/skills/create-agent-skills/workflows/add-workflow.md +120 -0
- package/skills/create-agent-skills/workflows/audit-skill.md +138 -0
- package/skills/create-agent-skills/workflows/create-domain-expertise-skill.md +605 -0
- package/skills/create-agent-skills/workflows/create-new-skill.md +191 -0
- package/skills/create-agent-skills/workflows/get-guidance.md +121 -0
- package/skills/create-agent-skills/workflows/upgrade-to-router.md +161 -0
- package/skills/create-agent-skills/workflows/verify-skill.md +204 -0
- package/skills/data-integrity-guardian/SKILL.md +84 -0
- package/skills/data-migration-expert/SKILL.md +111 -0
- package/skills/deployment-verification-agent/SKILL.md +173 -0
- package/skills/design-implementation-reviewer/SKILL.md +107 -0
- package/skills/design-iterator/SKILL.md +222 -0
- package/skills/dhh-rails-reviewer/SKILL.md +65 -0
- package/skills/dhh-rails-style/SKILL.md +185 -0
- package/skills/dhh-rails-style/references/architecture.md +653 -0
- package/skills/dhh-rails-style/references/controllers.md +303 -0
- package/skills/dhh-rails-style/references/frontend.md +510 -0
- package/skills/dhh-rails-style/references/gems.md +266 -0
- package/skills/dhh-rails-style/references/models.md +359 -0
- package/skills/dhh-rails-style/references/testing.md +338 -0
- package/skills/document-review/SKILL.md +87 -0
- package/skills/dspy-ruby/SKILL.md +737 -0
- package/skills/dspy-ruby/assets/config-template.rb +187 -0
- package/skills/dspy-ruby/assets/module-template.rb +300 -0
- package/skills/dspy-ruby/assets/signature-template.rb +221 -0
- package/skills/dspy-ruby/references/core-concepts.md +674 -0
- package/skills/dspy-ruby/references/observability.md +366 -0
- package/skills/dspy-ruby/references/optimization.md +603 -0
- package/skills/dspy-ruby/references/providers.md +418 -0
- package/skills/dspy-ruby/references/toolsets.md +502 -0
- package/skills/every-style-editor/SKILL.md +134 -0
- package/skills/every-style-editor/references/EVERY_WRITE_STYLE.md +529 -0
- package/skills/every-style-editor-2/SKILL.md +62 -0
- package/skills/figma-design-sync/SKILL.md +188 -0
- package/skills/file-todos/SKILL.md +252 -0
- package/skills/file-todos/assets/todo-template.md +155 -0
- package/skills/framework-docs-researcher/SKILL.md +105 -0
- package/skills/frontend-design/SKILL.md +42 -0
- package/skills/gemini-imagegen/SKILL.md +237 -0
- package/skills/gemini-imagegen/requirements.txt +2 -0
- package/skills/gemini-imagegen/scripts/compose_images.py +157 -0
- package/skills/gemini-imagegen/scripts/edit_image.py +144 -0
- package/skills/gemini-imagegen/scripts/gemini_images.py +263 -0
- package/skills/gemini-imagegen/scripts/generate_image.py +133 -0
- package/skills/gemini-imagegen/scripts/multi_turn_chat.py +216 -0
- package/skills/git-history-analyzer/SKILL.md +58 -0
- package/skills/git-worktree/SKILL.md +302 -0
- package/skills/git-worktree/scripts/worktree-manager.sh +337 -0
- package/skills/julik-frontend-races-reviewer/SKILL.md +220 -0
- package/skills/kieran-python-reviewer/SKILL.md +132 -0
- package/skills/kieran-rails-reviewer/SKILL.md +114 -0
- package/skills/kieran-typescript-reviewer/SKILL.md +123 -0
- package/skills/learnings-researcher/SKILL.md +263 -0
- package/skills/lint/SKILL.md +14 -0
- package/skills/orchestrating-swarms/SKILL.md +1718 -0
- package/skills/pattern-recognition-specialist/SKILL.md +71 -0
- package/skills/performance-oracle/SKILL.md +136 -0
- package/skills/pr-comment-resolver/SKILL.md +82 -0
- package/skills/rclone/SKILL.md +150 -0
- package/skills/rclone/scripts/check_setup.sh +60 -0
- package/skills/repo-research-analyst/SKILL.md +134 -0
- package/skills/resolve_pr_parallel/SKILL.md +89 -0
- package/skills/resolve_pr_parallel/scripts/get-pr-comments +68 -0
- package/skills/resolve_pr_parallel/scripts/resolve-pr-thread +23 -0
- package/skills/schema-drift-detector/SKILL.md +153 -0
- package/skills/security-sentinel/SKILL.md +113 -0
- package/skills/skill-creator/SKILL.md +210 -0
- package/skills/skill-creator/scripts/init_skill.py +303 -0
- package/skills/skill-creator/scripts/package_skill.py +110 -0
- package/skills/skill-creator/scripts/quick_validate.py +65 -0
- package/skills/spec-flow-analyzer/SKILL.md +133 -0
- package/src/commands/convert.ts +183 -0
- package/src/commands/install.ts +273 -0
- package/src/commands/list.ts +37 -0
- package/src/commands/sync.ts +89 -0
- package/src/converters/claude-to-codex.ts +182 -0
- package/src/converters/claude-to-opencode.ts +395 -0
- package/src/converters/claude-to-pi.ts +205 -0
- package/src/index.ts +22 -0
- package/src/parsers/claude-home.ts +65 -0
- package/src/parsers/claude.ts +252 -0
- package/src/sync/codex.ts +92 -0
- package/src/sync/opencode.ts +75 -0
- package/src/sync/pi.ts +88 -0
- package/src/targets/codex.ts +96 -0
- package/src/targets/index.ts +38 -0
- package/src/targets/opencode.ts +57 -0
- package/src/targets/pi.ts +131 -0
- package/src/templates/pi/compat-extension.ts +452 -0
- package/src/types/claude.ts +90 -0
- package/src/types/codex.ts +23 -0
- package/src/types/opencode.ts +54 -0
- package/src/types/pi.ts +40 -0
- package/src/utils/codex-agents.ts +64 -0
- package/src/utils/files.ts +77 -0
- package/src/utils/frontmatter.ts +65 -0
- package/src/utils/symlink.ts +43 -0
|
@@ -0,0 +1,216 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
"""
|
|
3
|
+
Interactive multi-turn image generation and refinement using Gemini API.
|
|
4
|
+
|
|
5
|
+
Usage:
|
|
6
|
+
python multi_turn_chat.py [--model MODEL] [--output-dir DIR]
|
|
7
|
+
|
|
8
|
+
This starts an interactive session where you can:
|
|
9
|
+
- Generate images from prompts
|
|
10
|
+
- Iteratively refine images through conversation
|
|
11
|
+
- Load existing images for editing
|
|
12
|
+
- Save images at any point
|
|
13
|
+
|
|
14
|
+
Commands:
|
|
15
|
+
/save [filename] - Save current image
|
|
16
|
+
/load <path> - Load an image into the conversation
|
|
17
|
+
/clear - Start fresh conversation
|
|
18
|
+
/quit - Exit
|
|
19
|
+
|
|
20
|
+
Environment:
|
|
21
|
+
GEMINI_API_KEY - Required API key
|
|
22
|
+
"""
|
|
23
|
+
|
|
24
|
+
import argparse
|
|
25
|
+
import os
|
|
26
|
+
import sys
|
|
27
|
+
from datetime import datetime
|
|
28
|
+
from pathlib import Path
|
|
29
|
+
|
|
30
|
+
from PIL import Image
|
|
31
|
+
from google import genai
|
|
32
|
+
from google.genai import types
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
class ImageChat:
|
|
36
|
+
"""Interactive chat session for image generation and refinement."""
|
|
37
|
+
|
|
38
|
+
def __init__(
|
|
39
|
+
self,
|
|
40
|
+
model: str = "gemini-2.5-flash-image",
|
|
41
|
+
output_dir: str = ".",
|
|
42
|
+
):
|
|
43
|
+
api_key = os.environ.get("GEMINI_API_KEY")
|
|
44
|
+
if not api_key:
|
|
45
|
+
raise EnvironmentError("GEMINI_API_KEY environment variable not set")
|
|
46
|
+
|
|
47
|
+
self.client = genai.Client(api_key=api_key)
|
|
48
|
+
self.model = model
|
|
49
|
+
self.output_dir = Path(output_dir)
|
|
50
|
+
self.output_dir.mkdir(parents=True, exist_ok=True)
|
|
51
|
+
|
|
52
|
+
self.chat = None
|
|
53
|
+
self.current_image = None
|
|
54
|
+
self.image_count = 0
|
|
55
|
+
|
|
56
|
+
self._init_chat()
|
|
57
|
+
|
|
58
|
+
def _init_chat(self):
|
|
59
|
+
"""Initialize or reset the chat session."""
|
|
60
|
+
config = types.GenerateContentConfig(
|
|
61
|
+
response_modalities=["TEXT", "IMAGE"]
|
|
62
|
+
)
|
|
63
|
+
self.chat = self.client.chats.create(
|
|
64
|
+
model=self.model,
|
|
65
|
+
config=config,
|
|
66
|
+
)
|
|
67
|
+
self.current_image = None
|
|
68
|
+
|
|
69
|
+
def send_message(self, message: str, image: Image.Image | None = None) -> tuple[str | None, Image.Image | None]:
|
|
70
|
+
"""Send a message and optionally an image, return response text and image."""
|
|
71
|
+
contents = []
|
|
72
|
+
if message:
|
|
73
|
+
contents.append(message)
|
|
74
|
+
if image:
|
|
75
|
+
contents.append(image)
|
|
76
|
+
|
|
77
|
+
if not contents:
|
|
78
|
+
return None, None
|
|
79
|
+
|
|
80
|
+
response = self.chat.send_message(contents)
|
|
81
|
+
|
|
82
|
+
text_response = None
|
|
83
|
+
image_response = None
|
|
84
|
+
|
|
85
|
+
for part in response.parts:
|
|
86
|
+
if part.text is not None:
|
|
87
|
+
text_response = part.text
|
|
88
|
+
elif part.inline_data is not None:
|
|
89
|
+
image_response = part.as_image()
|
|
90
|
+
self.current_image = image_response
|
|
91
|
+
|
|
92
|
+
return text_response, image_response
|
|
93
|
+
|
|
94
|
+
def save_image(self, filename: str | None = None) -> str | None:
|
|
95
|
+
"""Save the current image to a file."""
|
|
96
|
+
if self.current_image is None:
|
|
97
|
+
return None
|
|
98
|
+
|
|
99
|
+
if filename is None:
|
|
100
|
+
self.image_count += 1
|
|
101
|
+
timestamp = datetime.now().strftime("%Y%m%d_%H%M%S")
|
|
102
|
+
filename = f"image_{timestamp}_{self.image_count}.png"
|
|
103
|
+
|
|
104
|
+
filepath = self.output_dir / filename
|
|
105
|
+
self.current_image.save(filepath)
|
|
106
|
+
return str(filepath)
|
|
107
|
+
|
|
108
|
+
def load_image(self, path: str) -> Image.Image:
|
|
109
|
+
"""Load an image from disk."""
|
|
110
|
+
img = Image.open(path)
|
|
111
|
+
self.current_image = img
|
|
112
|
+
return img
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
def main():
|
|
116
|
+
parser = argparse.ArgumentParser(
|
|
117
|
+
description="Interactive multi-turn image generation",
|
|
118
|
+
formatter_class=argparse.RawDescriptionHelpFormatter,
|
|
119
|
+
epilog=__doc__
|
|
120
|
+
)
|
|
121
|
+
parser.add_argument(
|
|
122
|
+
"--model", "-m",
|
|
123
|
+
default="gemini-2.5-flash-image",
|
|
124
|
+
choices=["gemini-2.5-flash-image", "gemini-3-pro-image-preview"],
|
|
125
|
+
help="Model to use"
|
|
126
|
+
)
|
|
127
|
+
parser.add_argument(
|
|
128
|
+
"--output-dir", "-o",
|
|
129
|
+
default=".",
|
|
130
|
+
help="Directory to save images"
|
|
131
|
+
)
|
|
132
|
+
|
|
133
|
+
args = parser.parse_args()
|
|
134
|
+
|
|
135
|
+
try:
|
|
136
|
+
chat = ImageChat(model=args.model, output_dir=args.output_dir)
|
|
137
|
+
except Exception as e:
|
|
138
|
+
print(f"Error initializing: {e}", file=sys.stderr)
|
|
139
|
+
sys.exit(1)
|
|
140
|
+
|
|
141
|
+
print(f"Gemini Image Chat ({args.model})")
|
|
142
|
+
print("Commands: /save [name], /load <path>, /clear, /quit")
|
|
143
|
+
print("-" * 50)
|
|
144
|
+
|
|
145
|
+
while True:
|
|
146
|
+
try:
|
|
147
|
+
user_input = input("\nYou: ").strip()
|
|
148
|
+
except (EOFError, KeyboardInterrupt):
|
|
149
|
+
print("\nGoodbye!")
|
|
150
|
+
break
|
|
151
|
+
|
|
152
|
+
if not user_input:
|
|
153
|
+
continue
|
|
154
|
+
|
|
155
|
+
# Handle commands
|
|
156
|
+
if user_input.startswith("/"):
|
|
157
|
+
parts = user_input.split(maxsplit=1)
|
|
158
|
+
cmd = parts[0].lower()
|
|
159
|
+
arg = parts[1] if len(parts) > 1 else None
|
|
160
|
+
|
|
161
|
+
if cmd == "/quit":
|
|
162
|
+
print("Goodbye!")
|
|
163
|
+
break
|
|
164
|
+
|
|
165
|
+
elif cmd == "/clear":
|
|
166
|
+
chat._init_chat()
|
|
167
|
+
print("Conversation cleared.")
|
|
168
|
+
continue
|
|
169
|
+
|
|
170
|
+
elif cmd == "/save":
|
|
171
|
+
path = chat.save_image(arg)
|
|
172
|
+
if path:
|
|
173
|
+
print(f"Image saved to: {path}")
|
|
174
|
+
else:
|
|
175
|
+
print("No image to save.")
|
|
176
|
+
continue
|
|
177
|
+
|
|
178
|
+
elif cmd == "/load":
|
|
179
|
+
if not arg:
|
|
180
|
+
print("Usage: /load <path>")
|
|
181
|
+
continue
|
|
182
|
+
try:
|
|
183
|
+
chat.load_image(arg)
|
|
184
|
+
print(f"Loaded: {arg}")
|
|
185
|
+
print("You can now describe edits to make.")
|
|
186
|
+
except Exception as e:
|
|
187
|
+
print(f"Error loading image: {e}")
|
|
188
|
+
continue
|
|
189
|
+
|
|
190
|
+
else:
|
|
191
|
+
print(f"Unknown command: {cmd}")
|
|
192
|
+
continue
|
|
193
|
+
|
|
194
|
+
# Send message to model
|
|
195
|
+
try:
|
|
196
|
+
# If we have a loaded image and this is first message, include it
|
|
197
|
+
image_to_send = None
|
|
198
|
+
if chat.current_image and not chat.chat.history:
|
|
199
|
+
image_to_send = chat.current_image
|
|
200
|
+
|
|
201
|
+
text, image = chat.send_message(user_input, image_to_send)
|
|
202
|
+
|
|
203
|
+
if text:
|
|
204
|
+
print(f"\nGemini: {text}")
|
|
205
|
+
|
|
206
|
+
if image:
|
|
207
|
+
# Auto-save
|
|
208
|
+
path = chat.save_image()
|
|
209
|
+
print(f"\n[Image generated: {path}]")
|
|
210
|
+
|
|
211
|
+
except Exception as e:
|
|
212
|
+
print(f"\nError: {e}")
|
|
213
|
+
|
|
214
|
+
|
|
215
|
+
if __name__ == "__main__":
|
|
216
|
+
main()
|
|
@@ -0,0 +1,302 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: git-worktree
|
|
3
|
+
description: This skill manages Git worktrees for isolated parallel development. It handles creating, listing, switching, and cleaning up worktrees with a simple interactive interface, following KISS principles.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Git Worktree Manager
|
|
7
|
+
|
|
8
|
+
This skill provides a unified interface for managing Git worktrees across your development workflow. Whether you're reviewing PRs in isolation or working on features in parallel, this skill handles all the complexity.
|
|
9
|
+
|
|
10
|
+
## What This Skill Does
|
|
11
|
+
|
|
12
|
+
- **Create worktrees** from main branch with clear branch names
|
|
13
|
+
- **List worktrees** with current status
|
|
14
|
+
- **Switch between worktrees** for parallel work
|
|
15
|
+
- **Clean up completed worktrees** automatically
|
|
16
|
+
- **Interactive confirmations** at each step
|
|
17
|
+
- **Automatic .gitignore management** for worktree directory
|
|
18
|
+
- **Automatic .env file copying** from main repo to new worktrees
|
|
19
|
+
|
|
20
|
+
## CRITICAL: Always Use the Manager Script
|
|
21
|
+
|
|
22
|
+
**NEVER call `git worktree add` directly.** Always use the `worktree-manager.sh` script.
|
|
23
|
+
|
|
24
|
+
The script handles critical setup that raw git commands don't:
|
|
25
|
+
1. Copies `.env`, `.env.local`, `.env.test`, etc. from main repo
|
|
26
|
+
2. Ensures `.worktrees` is in `.gitignore`
|
|
27
|
+
3. Creates consistent directory structure
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
# ✅ CORRECT - Always use the script
|
|
31
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh create feature-name
|
|
32
|
+
|
|
33
|
+
# ❌ WRONG - Never do this directly
|
|
34
|
+
git worktree add .worktrees/feature-name -b feature-name main
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
## When to Use This Skill
|
|
38
|
+
|
|
39
|
+
Use this skill in these scenarios:
|
|
40
|
+
|
|
41
|
+
1. **Code Review (`/workflows:review`)**: If NOT already on the target branch (PR branch or requested branch), offer worktree for isolated review
|
|
42
|
+
2. **Feature Work (`/workflows:work`)**: Always ask if user wants parallel worktree or live branch work
|
|
43
|
+
3. **Parallel Development**: When working on multiple features simultaneously
|
|
44
|
+
4. **Cleanup**: After completing work in a worktree
|
|
45
|
+
|
|
46
|
+
## How to Use
|
|
47
|
+
|
|
48
|
+
### In Claude Code Workflows
|
|
49
|
+
|
|
50
|
+
The skill is automatically called from `/workflows:review` and `/workflows:work` commands:
|
|
51
|
+
|
|
52
|
+
```
|
|
53
|
+
# For review: offers worktree if not on PR branch
|
|
54
|
+
# For work: always asks - new branch or worktree?
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
### Manual Usage
|
|
58
|
+
|
|
59
|
+
You can also invoke the skill directly from bash:
|
|
60
|
+
|
|
61
|
+
```bash
|
|
62
|
+
# Create a new worktree (copies .env files automatically)
|
|
63
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh create feature-login
|
|
64
|
+
|
|
65
|
+
# List all worktrees
|
|
66
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh list
|
|
67
|
+
|
|
68
|
+
# Switch to a worktree
|
|
69
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh switch feature-login
|
|
70
|
+
|
|
71
|
+
# Copy .env files to an existing worktree (if they weren't copied)
|
|
72
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh copy-env feature-login
|
|
73
|
+
|
|
74
|
+
# Clean up completed worktrees
|
|
75
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh cleanup
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
## Commands
|
|
79
|
+
|
|
80
|
+
### `create <branch-name> [from-branch]`
|
|
81
|
+
|
|
82
|
+
Creates a new worktree with the given branch name.
|
|
83
|
+
|
|
84
|
+
**Options:**
|
|
85
|
+
- `branch-name` (required): The name for the new branch and worktree
|
|
86
|
+
- `from-branch` (optional): Base branch to create from (defaults to `main`)
|
|
87
|
+
|
|
88
|
+
**Example:**
|
|
89
|
+
```bash
|
|
90
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh create feature-login
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
**What happens:**
|
|
94
|
+
1. Checks if worktree already exists
|
|
95
|
+
2. Updates the base branch from remote
|
|
96
|
+
3. Creates new worktree and branch
|
|
97
|
+
4. **Copies all .env files from main repo** (.env, .env.local, .env.test, etc.)
|
|
98
|
+
5. Shows path for cd-ing to the worktree
|
|
99
|
+
|
|
100
|
+
### `list` or `ls`
|
|
101
|
+
|
|
102
|
+
Lists all available worktrees with their branches and current status.
|
|
103
|
+
|
|
104
|
+
**Example:**
|
|
105
|
+
```bash
|
|
106
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh list
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
**Output shows:**
|
|
110
|
+
- Worktree name
|
|
111
|
+
- Branch name
|
|
112
|
+
- Which is current (marked with ✓)
|
|
113
|
+
- Main repo status
|
|
114
|
+
|
|
115
|
+
### `switch <name>` or `go <name>`
|
|
116
|
+
|
|
117
|
+
Switches to an existing worktree and cd's into it.
|
|
118
|
+
|
|
119
|
+
**Example:**
|
|
120
|
+
```bash
|
|
121
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh switch feature-login
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
**Optional:**
|
|
125
|
+
- If name not provided, lists available worktrees and prompts for selection
|
|
126
|
+
|
|
127
|
+
### `cleanup` or `clean`
|
|
128
|
+
|
|
129
|
+
Interactively cleans up inactive worktrees with confirmation.
|
|
130
|
+
|
|
131
|
+
**Example:**
|
|
132
|
+
```bash
|
|
133
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh cleanup
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
**What happens:**
|
|
137
|
+
1. Lists all inactive worktrees
|
|
138
|
+
2. Asks for confirmation
|
|
139
|
+
3. Removes selected worktrees
|
|
140
|
+
4. Cleans up empty directories
|
|
141
|
+
|
|
142
|
+
## Workflow Examples
|
|
143
|
+
|
|
144
|
+
### Code Review with Worktree
|
|
145
|
+
|
|
146
|
+
```bash
|
|
147
|
+
# Claude Code recognizes you're not on the PR branch
|
|
148
|
+
# Offers: "Use worktree for isolated review? (y/n)"
|
|
149
|
+
|
|
150
|
+
# You respond: yes
|
|
151
|
+
# Script runs (copies .env files automatically):
|
|
152
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh create pr-123-feature-name
|
|
153
|
+
|
|
154
|
+
# You're now in isolated worktree for review with all env vars
|
|
155
|
+
cd .worktrees/pr-123-feature-name
|
|
156
|
+
|
|
157
|
+
# After review, return to main:
|
|
158
|
+
cd ../..
|
|
159
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh cleanup
|
|
160
|
+
```
|
|
161
|
+
|
|
162
|
+
### Parallel Feature Development
|
|
163
|
+
|
|
164
|
+
```bash
|
|
165
|
+
# For first feature (copies .env files):
|
|
166
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh create feature-login
|
|
167
|
+
|
|
168
|
+
# Later, start second feature (also copies .env files):
|
|
169
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh create feature-notifications
|
|
170
|
+
|
|
171
|
+
# List what you have:
|
|
172
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh list
|
|
173
|
+
|
|
174
|
+
# Switch between them as needed:
|
|
175
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh switch feature-login
|
|
176
|
+
|
|
177
|
+
# Return to main and cleanup when done:
|
|
178
|
+
cd .
|
|
179
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh cleanup
|
|
180
|
+
```
|
|
181
|
+
|
|
182
|
+
## Key Design Principles
|
|
183
|
+
|
|
184
|
+
### KISS (Keep It Simple, Stupid)
|
|
185
|
+
|
|
186
|
+
- **One manager script** handles all worktree operations
|
|
187
|
+
- **Simple commands** with sensible defaults
|
|
188
|
+
- **Interactive prompts** prevent accidental operations
|
|
189
|
+
- **Clear naming** using branch names directly
|
|
190
|
+
|
|
191
|
+
### Opinionated Defaults
|
|
192
|
+
|
|
193
|
+
- Worktrees always created from **main** (unless specified)
|
|
194
|
+
- Worktrees stored in **.worktrees/** directory
|
|
195
|
+
- Branch name becomes worktree name
|
|
196
|
+
- **.gitignore** automatically managed
|
|
197
|
+
|
|
198
|
+
### Safety First
|
|
199
|
+
|
|
200
|
+
- **Confirms before creating** worktrees
|
|
201
|
+
- **Confirms before cleanup** to prevent accidental removal
|
|
202
|
+
- **Won't remove current worktree**
|
|
203
|
+
- **Clear error messages** for issues
|
|
204
|
+
|
|
205
|
+
## Integration with Workflows
|
|
206
|
+
|
|
207
|
+
### `/workflows:review`
|
|
208
|
+
|
|
209
|
+
Instead of always creating a worktree:
|
|
210
|
+
|
|
211
|
+
```
|
|
212
|
+
1. Check current branch
|
|
213
|
+
2. If ALREADY on target branch (PR branch or requested branch) → stay there, no worktree needed
|
|
214
|
+
3. If DIFFERENT branch than the review target → offer worktree:
|
|
215
|
+
"Use worktree for isolated review? (y/n)"
|
|
216
|
+
- yes → call git-worktree skill
|
|
217
|
+
- no → proceed with PR diff on current branch
|
|
218
|
+
```
|
|
219
|
+
|
|
220
|
+
### `/workflows:work`
|
|
221
|
+
|
|
222
|
+
Always offer choice:
|
|
223
|
+
|
|
224
|
+
```
|
|
225
|
+
1. Ask: "How do you want to work?
|
|
226
|
+
1. New branch on current worktree (live work)
|
|
227
|
+
2. Worktree (parallel work)"
|
|
228
|
+
|
|
229
|
+
2. If choice 1 → create new branch normally
|
|
230
|
+
3. If choice 2 → call git-worktree skill to create from main
|
|
231
|
+
```
|
|
232
|
+
|
|
233
|
+
## Troubleshooting
|
|
234
|
+
|
|
235
|
+
### "Worktree already exists"
|
|
236
|
+
|
|
237
|
+
If you see this, the script will ask if you want to switch to it instead.
|
|
238
|
+
|
|
239
|
+
### "Cannot remove worktree: it is the current worktree"
|
|
240
|
+
|
|
241
|
+
Switch out of the worktree first (to main repo), then cleanup:
|
|
242
|
+
|
|
243
|
+
```bash
|
|
244
|
+
cd $(git rev-parse --show-toplevel)
|
|
245
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh cleanup
|
|
246
|
+
```
|
|
247
|
+
|
|
248
|
+
### Lost in a worktree?
|
|
249
|
+
|
|
250
|
+
See where you are:
|
|
251
|
+
|
|
252
|
+
```bash
|
|
253
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh list
|
|
254
|
+
```
|
|
255
|
+
|
|
256
|
+
### .env files missing in worktree?
|
|
257
|
+
|
|
258
|
+
If a worktree was created without .env files (e.g., via raw `git worktree add`), copy them:
|
|
259
|
+
|
|
260
|
+
```bash
|
|
261
|
+
bash ${CLAUDE_PLUGIN_ROOT}/skills/git-worktree/scripts/worktree-manager.sh copy-env feature-name
|
|
262
|
+
```
|
|
263
|
+
|
|
264
|
+
Navigate back to main:
|
|
265
|
+
|
|
266
|
+
```bash
|
|
267
|
+
cd $(git rev-parse --show-toplevel)
|
|
268
|
+
```
|
|
269
|
+
|
|
270
|
+
## Technical Details
|
|
271
|
+
|
|
272
|
+
### Directory Structure
|
|
273
|
+
|
|
274
|
+
```
|
|
275
|
+
.worktrees/
|
|
276
|
+
├── feature-login/ # Worktree 1
|
|
277
|
+
│ ├── .git
|
|
278
|
+
│ ├── app/
|
|
279
|
+
│ └── ...
|
|
280
|
+
├── feature-notifications/ # Worktree 2
|
|
281
|
+
│ ├── .git
|
|
282
|
+
│ ├── app/
|
|
283
|
+
│ └── ...
|
|
284
|
+
└── ...
|
|
285
|
+
|
|
286
|
+
.gitignore (updated to include .worktrees)
|
|
287
|
+
```
|
|
288
|
+
|
|
289
|
+
### How It Works
|
|
290
|
+
|
|
291
|
+
- Uses `git worktree add` for isolated environments
|
|
292
|
+
- Each worktree has its own branch
|
|
293
|
+
- Changes in one worktree don't affect others
|
|
294
|
+
- Share git history with main repo
|
|
295
|
+
- Can push from any worktree
|
|
296
|
+
|
|
297
|
+
### Performance
|
|
298
|
+
|
|
299
|
+
- Worktrees are lightweight (just file system links)
|
|
300
|
+
- No repository duplication
|
|
301
|
+
- Shared git objects for efficiency
|
|
302
|
+
- Much faster than cloning or stashing/switching
|