ima-claude 2.9.0

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.
Files changed (182) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +463 -0
  3. package/dist/cli.js +1064 -0
  4. package/package.json +49 -0
  5. package/platforms/claude/adapter.ts +115 -0
  6. package/platforms/junie/adapter.ts +254 -0
  7. package/platforms/junie/agents-template.md +113 -0
  8. package/platforms/junie/hook-translations.md +84 -0
  9. package/platforms/shared/detector.ts +27 -0
  10. package/platforms/shared/installer.ts +202 -0
  11. package/platforms/shared/types.ts +78 -0
  12. package/plugins/ima-claude/.claude-plugin/plugin.json +25 -0
  13. package/plugins/ima-claude/agents/explorer.md +30 -0
  14. package/plugins/ima-claude/agents/implementer.md +30 -0
  15. package/plugins/ima-claude/agents/memory.md +42 -0
  16. package/plugins/ima-claude/agents/reviewer.md +53 -0
  17. package/plugins/ima-claude/agents/tester.md +33 -0
  18. package/plugins/ima-claude/agents/wp-developer.md +46 -0
  19. package/plugins/ima-claude/hooks/README.md +145 -0
  20. package/plugins/ima-claude/hooks/atlassian_prereqs.py +112 -0
  21. package/plugins/ima-claude/hooks/block_sed_edits.py +59 -0
  22. package/plugins/ima-claude/hooks/bootstrap.sh +90 -0
  23. package/plugins/ima-claude/hooks/bootstrap_utility_check.py +94 -0
  24. package/plugins/ima-claude/hooks/composer_autoload_check.py +70 -0
  25. package/plugins/ima-claude/hooks/docs_organization.py +104 -0
  26. package/plugins/ima-claude/hooks/enforce_rg_over_grep.py +56 -0
  27. package/plugins/ima-claude/hooks/fp_utility_check.py +90 -0
  28. package/plugins/ima-claude/hooks/hook_logger.py +69 -0
  29. package/plugins/ima-claude/hooks/hooks.json +239 -0
  30. package/plugins/ima-claude/hooks/jira_issue_fetch.py +79 -0
  31. package/plugins/ima-claude/hooks/jquery_in_wordpress.py +92 -0
  32. package/plugins/ima-claude/hooks/memory_bootstrap.py +79 -0
  33. package/plugins/ima-claude/hooks/memory_store_reminder.py +75 -0
  34. package/plugins/ima-claude/hooks/prompt_coach.py +125 -0
  35. package/plugins/ima-claude/hooks/prompt_coach_digest.md +48 -0
  36. package/plugins/ima-claude/hooks/prompt_coach_system.md +30 -0
  37. package/plugins/ima-claude/hooks/sequential_thinking_check.py +81 -0
  38. package/plugins/ima-claude/hooks/serena_over_grep.py +96 -0
  39. package/plugins/ima-claude/hooks/serena_over_read.py +66 -0
  40. package/plugins/ima-claude/hooks/serena_project_check.py +133 -0
  41. package/plugins/ima-claude/hooks/sql_injection_check.py +73 -0
  42. package/plugins/ima-claude/hooks/task_master_after_plan.py +31 -0
  43. package/plugins/ima-claude/hooks/task_master_before_impl.py +93 -0
  44. package/plugins/ima-claude/hooks/tavily_extract_advanced.py +48 -0
  45. package/plugins/ima-claude/hooks/vestige_before_external.py +86 -0
  46. package/plugins/ima-claude/hooks/webfetch_to_tavily.py +42 -0
  47. package/plugins/ima-claude/hooks/websearch_to_tavily.py +41 -0
  48. package/plugins/ima-claude/hooks/wp_security_check.py +150 -0
  49. package/plugins/ima-claude/personalities/README.md +45 -0
  50. package/plugins/ima-claude/personalities/enable-40k.md +69 -0
  51. package/plugins/ima-claude/personalities/enable-templars.md +69 -0
  52. package/plugins/ima-claude/skills/.research-summary.md +340 -0
  53. package/plugins/ima-claude/skills/architect/SKILL.md +304 -0
  54. package/plugins/ima-claude/skills/compound-bridge/SKILL.md +200 -0
  55. package/plugins/ima-claude/skills/discourse/SKILL.md +440 -0
  56. package/plugins/ima-claude/skills/discourse-admin/SKILL.md +192 -0
  57. package/plugins/ima-claude/skills/discourse-admin/references/api-endpoints.md +441 -0
  58. package/plugins/ima-claude/skills/discourse-admin/references/gotchas.md +107 -0
  59. package/plugins/ima-claude/skills/discourse-admin/references/staging-defaults.md +98 -0
  60. package/plugins/ima-claude/skills/discourse-admin/scripts/discourse-admin.py +319 -0
  61. package/plugins/ima-claude/skills/docs-organize/SKILL.md +254 -0
  62. package/plugins/ima-claude/skills/docs-organize/templates/active-README.md +50 -0
  63. package/plugins/ima-claude/skills/docs-organize/templates/archive-README.md +57 -0
  64. package/plugins/ima-claude/skills/docs-organize/templates/docs-README.md +43 -0
  65. package/plugins/ima-claude/skills/docs-organize/templates/phase-archive-README.md +83 -0
  66. package/plugins/ima-claude/skills/docs-organize/templates/section-README.md +48 -0
  67. package/plugins/ima-claude/skills/docs-organize/templates/transient-README.md +79 -0
  68. package/plugins/ima-claude/skills/docs-organize/templates/transient-gitignore +9 -0
  69. package/plugins/ima-claude/skills/ember-discourse/SKILL.md +496 -0
  70. package/plugins/ima-claude/skills/functional-programmer/SKILL.md +258 -0
  71. package/plugins/ima-claude/skills/ima-bootstrap/SKILL.md +278 -0
  72. package/plugins/ima-claude/skills/ima-bootstrap/references/bootstrap-patterns.md +356 -0
  73. package/plugins/ima-claude/skills/ima-bootstrap/references/ima-brand.md +273 -0
  74. package/plugins/ima-claude/skills/ima-bootstrap/references/theme-integration.md +212 -0
  75. package/plugins/ima-claude/skills/ima-brand/SKILL.md +108 -0
  76. package/plugins/ima-claude/skills/ima-brand/references/brand-identity.md +140 -0
  77. package/plugins/ima-claude/skills/ima-brand/references/digital-standards.md +180 -0
  78. package/plugins/ima-claude/skills/ima-brand/references/visual-system.md +173 -0
  79. package/plugins/ima-claude/skills/ima-forms-expert/SKILL.md +175 -0
  80. package/plugins/ima-claude/skills/ima-forms-expert/references/container-components.md +154 -0
  81. package/plugins/ima-claude/skills/ima-forms-expert/references/examples.md +328 -0
  82. package/plugins/ima-claude/skills/ima-forms-expert/references/field-components.md +298 -0
  83. package/plugins/ima-claude/skills/ima-forms-expert/references/form-factory.md +193 -0
  84. package/plugins/ima-claude/skills/ima-forms-expert/references/quick-reference.md +153 -0
  85. package/plugins/ima-claude/skills/ima-forms-expert/references/validation-engine.md +336 -0
  86. package/plugins/ima-claude/skills/jira-checkpoint/SKILL.md +178 -0
  87. package/plugins/ima-claude/skills/jquery/SKILL.md +413 -0
  88. package/plugins/ima-claude/skills/js-fp/SKILL.md +463 -0
  89. package/plugins/ima-claude/skills/js-fp/core-principles.md +487 -0
  90. package/plugins/ima-claude/skills/js-fp/examples/pure-functions.js +260 -0
  91. package/plugins/ima-claude/skills/js-fp/examples/tests/pure-functions.test.js +262 -0
  92. package/plugins/ima-claude/skills/js-fp/references/anti-patterns.md +120 -0
  93. package/plugins/ima-claude/skills/js-fp/references/performance-patterns.md +116 -0
  94. package/plugins/ima-claude/skills/js-fp/references/testing-patterns.md +134 -0
  95. package/plugins/ima-claude/skills/js-fp-api/SKILL.md +280 -0
  96. package/plugins/ima-claude/skills/js-fp-api/examples/crud-endpoint.js +258 -0
  97. package/plugins/ima-claude/skills/js-fp-api/references/middleware-patterns.md +134 -0
  98. package/plugins/ima-claude/skills/js-fp-api/references/security-sql.md +110 -0
  99. package/plugins/ima-claude/skills/js-fp-api/references/validation-patterns.md +165 -0
  100. package/plugins/ima-claude/skills/js-fp-react/SKILL.md +447 -0
  101. package/plugins/ima-claude/skills/js-fp-react/examples/ProductCard.tsx +65 -0
  102. package/plugins/ima-claude/skills/js-fp-react/references/hooks-advanced.md +136 -0
  103. package/plugins/ima-claude/skills/js-fp-react/references/performance-patterns.md +175 -0
  104. package/plugins/ima-claude/skills/js-fp-vue/SKILL.md +322 -0
  105. package/plugins/ima-claude/skills/js-fp-vue/references/complete-examples.md +397 -0
  106. package/plugins/ima-claude/skills/js-fp-vue/references/composables-advanced.md +282 -0
  107. package/plugins/ima-claude/skills/js-fp-vue/references/reactivity-patterns.md +348 -0
  108. package/plugins/ima-claude/skills/js-fp-vue/references/testing.md +314 -0
  109. package/plugins/ima-claude/skills/js-fp-wordpress/SKILL.md +301 -0
  110. package/plugins/ima-claude/skills/js-fp-wordpress/references/ajax-patterns.md +192 -0
  111. package/plugins/ima-claude/skills/js-fp-wordpress/references/event-patterns.md +136 -0
  112. package/plugins/ima-claude/skills/js-fp-wordpress/references/wp-integration.md +248 -0
  113. package/plugins/ima-claude/skills/livecanvas/SKILL.md +209 -0
  114. package/plugins/ima-claude/skills/livecanvas/references/livecanvas-features.md +311 -0
  115. package/plugins/ima-claude/skills/livecanvas/references/loops-and-logic.md +730 -0
  116. package/plugins/ima-claude/skills/livecanvas/references/picostrap.md +227 -0
  117. package/plugins/ima-claude/skills/mcp-atlassian/SKILL.md +339 -0
  118. package/plugins/ima-claude/skills/mcp-context7/SKILL.md +109 -0
  119. package/plugins/ima-claude/skills/mcp-memory/SKILL.md +182 -0
  120. package/plugins/ima-claude/skills/mcp-qdrant/SKILL.md +233 -0
  121. package/plugins/ima-claude/skills/mcp-sequential/SKILL.md +149 -0
  122. package/plugins/ima-claude/skills/mcp-serena/SKILL.md +174 -0
  123. package/plugins/ima-claude/skills/mcp-tavily/SKILL.md +118 -0
  124. package/plugins/ima-claude/skills/mcp-vestige/SKILL.md +259 -0
  125. package/plugins/ima-claude/skills/php-authnet/SKILL.md +275 -0
  126. package/plugins/ima-claude/skills/php-authnet/references/api-reference.md +624 -0
  127. package/plugins/ima-claude/skills/php-authnet/references/sandbox-testing.md +424 -0
  128. package/plugins/ima-claude/skills/php-fp/SKILL.md +333 -0
  129. package/plugins/ima-claude/skills/php-fp/examples/pure-functions.php +403 -0
  130. package/plugins/ima-claude/skills/php-fp/examples/tests/PureFunctionsTest.php +515 -0
  131. package/plugins/ima-claude/skills/php-fp/references/core-principles.md +277 -0
  132. package/plugins/ima-claude/skills/php-fp/references/testing-patterns.md +374 -0
  133. package/plugins/ima-claude/skills/php-fp-wordpress/SKILL.md +216 -0
  134. package/plugins/ima-claude/skills/php-fp-wordpress/references/fp-patterns.md +275 -0
  135. package/plugins/ima-claude/skills/php-fp-wordpress/references/plugin-architecture.md +295 -0
  136. package/plugins/ima-claude/skills/php-fp-wordpress/references/security-examples.md +203 -0
  137. package/plugins/ima-claude/skills/php-fp-wordpress/references/testing-strategy.md +259 -0
  138. package/plugins/ima-claude/skills/phpunit-wp/SKILL.md +716 -0
  139. package/plugins/ima-claude/skills/playwright/SKILL.md +434 -0
  140. package/plugins/ima-claude/skills/playwright/references/accessibility-testing.md +153 -0
  141. package/plugins/ima-claude/skills/playwright/references/ci-cd.md +268 -0
  142. package/plugins/ima-claude/skills/playwright/references/network-mocking.md +270 -0
  143. package/plugins/ima-claude/skills/playwright/references/visual-regression.md +215 -0
  144. package/plugins/ima-claude/skills/py-fp/SKILL.md +663 -0
  145. package/plugins/ima-claude/skills/py-fp/examples/pure-functions.py +185 -0
  146. package/plugins/ima-claude/skills/py-fp/examples/tests/test_pure_functions.py +244 -0
  147. package/plugins/ima-claude/skills/py-fp/references/core-principles.md +381 -0
  148. package/plugins/ima-claude/skills/py-fp/references/testing-patterns.md +283 -0
  149. package/plugins/ima-claude/skills/quasar-fp/SKILL.md +327 -0
  150. package/plugins/ima-claude/skills/quasar-fp/metadata.json +85 -0
  151. package/plugins/ima-claude/skills/quasar-fp/references/component-patterns.md +257 -0
  152. package/plugins/ima-claude/skills/quasar-fp/references/theme-integration.md +233 -0
  153. package/plugins/ima-claude/skills/quasar-fp/references/utility-classes.md +237 -0
  154. package/plugins/ima-claude/skills/quickstart/SKILL.md +129 -0
  155. package/plugins/ima-claude/skills/rails/SKILL.md +359 -0
  156. package/plugins/ima-claude/skills/resume-session/SKILL.md +68 -0
  157. package/plugins/ima-claude/skills/rg/SKILL.md +205 -0
  158. package/plugins/ima-claude/skills/ruby-fp/SKILL.md +336 -0
  159. package/plugins/ima-claude/skills/save-session/SKILL.md +81 -0
  160. package/plugins/ima-claude/skills/scorecard/SKILL.md +96 -0
  161. package/plugins/ima-claude/skills/skill-analyzer/SKILL.md +127 -0
  162. package/plugins/ima-claude/skills/skill-analyzer/references/advanced-checklist.md +44 -0
  163. package/plugins/ima-claude/skills/skill-analyzer/references/core-checklist.md +60 -0
  164. package/plugins/ima-claude/skills/skill-analyzer/scripts/analyze_skill.py +418 -0
  165. package/plugins/ima-claude/skills/skill-creator/LICENSE.txt +202 -0
  166. package/plugins/ima-claude/skills/skill-creator/SKILL.md +343 -0
  167. package/plugins/ima-claude/skills/skill-creator/references/output-patterns.md +82 -0
  168. package/plugins/ima-claude/skills/skill-creator/references/workflows.md +28 -0
  169. package/plugins/ima-claude/skills/skill-creator/scripts/init_skill.py +303 -0
  170. package/plugins/ima-claude/skills/skill-creator/scripts/package_skill.py +110 -0
  171. package/plugins/ima-claude/skills/skill-creator/scripts/quick_validate.py +103 -0
  172. package/plugins/ima-claude/skills/task-master/SKILL.md +51 -0
  173. package/plugins/ima-claude/skills/task-planner/SKILL.md +228 -0
  174. package/plugins/ima-claude/skills/task-runner/SKILL.md +192 -0
  175. package/plugins/ima-claude/skills/unit-testing/SKILL.md +198 -0
  176. package/plugins/ima-claude/skills/unit-testing/references/mock-patterns.md +181 -0
  177. package/plugins/ima-claude/skills/unit-testing/references/tdd-workflow.md +177 -0
  178. package/plugins/ima-claude/skills/unit-testing/references/test-strategy.md +126 -0
  179. package/plugins/ima-claude/skills/wp-local/SKILL.md +246 -0
  180. package/plugins/ima-claude/skills/wp-local/references/configuration.md +198 -0
  181. package/plugins/ima-claude/skills/wp-local/references/wp-cli-reference.md +406 -0
  182. package/plugins/ima-claude/skills/wp-local/scripts/wp-local.sh +61 -0
@@ -0,0 +1,246 @@
1
+ ---
2
+ name: "wp-local"
3
+ description: "Run WordPress WP-CLI commands in Flywheel Local WP environments. Use for database queries, plugin management, user operations, theme operations, cache clearing, cron jobs. Auto-configures environment without affecting main Claude session. Triggers on: wp plugin, wp db, wp user, wp option, wp-cli, Local WP, Flywheel."
4
+ ---
5
+
6
+ # WordPress WP-Local
7
+
8
+ Execute WP-CLI commands in Flywheel Local WP environments without disrupting Claude Code's main session.
9
+
10
+ ## Quick Start
11
+
12
+ **Prerequisites**:
13
+ - **Recommended**: Use Kitty terminal with `$WP_LOCAL_SITE` configured (see Configuration)
14
+ - **Alternative**: Create `.wp-local` file in project root: `echo "19efkkzWB" > .wp-local`
15
+
16
+ **Run wp commands**:
17
+ ```bash
18
+ bash ~/.claude/skills/wp-local/scripts/wp-local.sh plugin list
19
+ bash ~/.claude/skills/wp-local/scripts/wp-local.sh db query "SELECT * FROM wp_posts LIMIT 5"
20
+ bash ~/.claude/skills/wp-local/scripts/wp-local.sh user list
21
+ ```
22
+
23
+ **With shell alias** (recommended, see Configuration):
24
+ ```bash
25
+ wpl plugin list
26
+ wpl db query "SELECT * FROM wp_users"
27
+ ```
28
+
29
+ **Verify configuration**:
30
+ ```bash
31
+ echo $WP_LOCAL_SITE # Should show UUID like: -hJRW0lQL
32
+ ```
33
+
34
+ ## How It Works
35
+
36
+ 1. **Kitty integration**: `$WP_LOCAL_SITE` env var set by Kitty config (or `.wp-local` file fallback)
37
+ 2. **Isolated execution**: Each wp command runs in subprocess with Local WP environment sourced
38
+ 3. **Clean main session**: Claude Code tab environment unaffected (MCPs work normally)
39
+ 4. **Friendly names**: Optional mapping via `~/.claude/wp-local-sites.json`
40
+
41
+ **Priority order:**
42
+ 1. `$WP_LOCAL_SITE` environment variable (Kitty terminal integration)
43
+ 2. `.wp-local` file (project-specific override)
44
+ 3. Error if neither configured
45
+
46
+ ## Common Commands
47
+
48
+ ### Database Operations
49
+ `wp db query <sql>` · `wp db export [file]` · `wp db import <file>` · `wp search-replace <old> <new> [table...]`
50
+ ```bash
51
+ wpl db query "SELECT * FROM wp_users"
52
+ wpl db export dump.sql
53
+ wpl db import dump.sql
54
+ wpl search-replace 'old.com' 'new.com' --dry-run
55
+ wpl search-replace 'old.com' 'new.com' --all-tables
56
+ ```
57
+
58
+ ### Plugin Management
59
+ `wp plugin list` · `wp plugin activate <plugin>` · `wp plugin deactivate <plugin>` · `wp plugin install <plugin> [--activate]`
60
+ ```bash
61
+ wpl plugin list
62
+ wpl plugin list --status=active --format=json
63
+ wpl plugin activate my-plugin
64
+ wpl plugin deactivate my-plugin
65
+ wpl plugin install contact-form-7 --activate
66
+ wpl plugin is-installed woocommerce && echo "yes"
67
+ ```
68
+
69
+ ### User Operations
70
+ `wp user list` · `wp user create <login> <email> [--role=<role>]` · `wp user update <user> [--field=value]`
71
+ ```bash
72
+ wpl user list
73
+ wpl user list --role=administrator --format=table
74
+ wpl user create testuser test@example.com --role=editor
75
+ wpl user update 1 --display_name="Admin User"
76
+ wpl user add-role 2 editor
77
+ ```
78
+
79
+ ### Theme Operations
80
+ `wp theme list` · `wp theme activate <theme>` · `wp theme install <theme>`
81
+ ```bash
82
+ wpl theme list
83
+ wpl theme activate twentytwentyfour
84
+ wpl theme status flavor
85
+ ```
86
+
87
+ ### Cache & Transients
88
+ `wp cache flush` · `wp transient delete --all` · `wp transient get <key>`
89
+ ```bash
90
+ wpl cache flush
91
+ wpl transient delete --all
92
+ wpl transient get my_transient_key
93
+ wpl transient list --format=table
94
+ ```
95
+
96
+ ### Options
97
+ `wp option get <key>` · `wp option update <key> <value>` · `wp option list [--search=<pattern>]`
98
+ ```bash
99
+ wpl option get siteurl
100
+ wpl option update blogname "New Site Name"
101
+ wpl option list --search="woocommerce_*" --format=table
102
+ wpl option delete my_old_option
103
+ ```
104
+
105
+ ### Post & Content
106
+ `wp post list [--post_type=<type>]` · `wp post create` · `wp post update <id>` · `wp post delete <id>`
107
+ ```bash
108
+ wpl post list --post_type=page --format=table
109
+ wpl post list --post_status=draft --fields=ID,post_title
110
+ wpl post create --post_type=post --post_title="Test" --post_status=publish
111
+ wpl post update 42 --post_title="Updated Title"
112
+ wpl post delete 42 --force
113
+ wpl post meta get 42 _thumbnail_id
114
+ wpl post meta update 42 custom_field "new value"
115
+ ```
116
+
117
+ ### Taxonomy & Terms
118
+ `wp term list <taxonomy>` · `wp term create <taxonomy> <term>` · `wp term update <taxonomy> <term-id>`
119
+ ```bash
120
+ wpl term list category --format=table
121
+ wpl term create category "New Category" --slug=new-category
122
+ wpl term update category 5 --name="Renamed"
123
+ wpl term delete category 5
124
+ ```
125
+
126
+ ### Menu
127
+ `wp menu list` · `wp menu item list <menu>` · `wp menu item add-post <menu> <post-id>`
128
+ ```bash
129
+ wpl menu list --format=table
130
+ wpl menu item list primary-menu
131
+ wpl menu item add-post primary-menu 42
132
+ wpl menu item add-custom primary-menu "Link" https://example.com
133
+ ```
134
+
135
+ ### Rewrite Rules
136
+ `wp rewrite flush` · `wp rewrite list` · `wp rewrite structure <structure>`
137
+ ```bash
138
+ wpl rewrite flush
139
+ wpl rewrite list --format=csv
140
+ wpl rewrite structure '/%postname%/'
141
+ ```
142
+
143
+ ### Scaffold
144
+ `wp scaffold plugin <slug>` · `wp scaffold child-theme <slug>` · `wp scaffold post-type <slug>`
145
+ ```bash
146
+ wpl scaffold plugin my-plugin --plugin_name="My Plugin"
147
+ wpl scaffold post-type product --plugin=my-plugin
148
+ wpl scaffold taxonomy genre --post_types=product --plugin=my-plugin
149
+ wpl scaffold child-theme flavor-child --parent_theme=flavor
150
+ ```
151
+
152
+ ### Eval & Shell
153
+ `wp eval <code>` · `wp eval-file <file>` · `wp shell`
154
+ ```bash
155
+ wpl eval "echo home_url();"
156
+ wpl eval "var_dump(wp_get_current_user());"
157
+ wpl eval "echo get_option('active_plugins') | print_r;"
158
+ wpl eval-file test-script.php
159
+ ```
160
+
161
+ ## Global Flags
162
+
163
+ These flags work with most WP-CLI commands:
164
+
165
+ | Flag | Description |
166
+ |---|---|
167
+ | `--format=<format>` | Output: `table`, `csv`, `json`, `yaml`, `count`, `ids` |
168
+ | `--fields=<fields>` | Comma-separated columns to display |
169
+ | `--quiet` | Suppress informational messages |
170
+ | `--skip-themes` | Skip loading themes (faster execution) |
171
+ | `--skip-plugins` | Skip loading all plugins (debug conflicts) |
172
+ | `--skip-plugins=<plugin>` | Skip loading specific plugin |
173
+ | `--debug` | Show debug output |
174
+ | `--user=<id\|login>` | Run command as specific user |
175
+
176
+ ## Finding More Commands
177
+
178
+ The 12 categories above cover ~90% of daily local dev usage. For everything else:
179
+
180
+ ```bash
181
+ # Browse all available commands
182
+ wpl help
183
+
184
+ # Get detailed help for a command group
185
+ wpl help plugin
186
+ wpl help post
187
+
188
+ # Get help for a specific subcommand
189
+ wpl help plugin install
190
+ wpl help post list
191
+ ```
192
+
193
+ See [`references/wp-cli-reference.md`](references/wp-cli-reference.md) for a comprehensive reference covering 20+ command groups including core, cron, media, comment, role/cap, config, widget, sidebar, i18n, import/export, and more.
194
+
195
+ ## Configuration
196
+
197
+ See [`references/configuration.md`](references/configuration.md) for:
198
+ - **Recommended**: Kitty terminal integration with `$WP_LOCAL_SITE`
199
+ - **Alternative**: Creating `.wp-local` file for project-specific override
200
+ - Finding site UUIDs
201
+ - Setting up friendly name mapping
202
+ - Shell alias setup
203
+ - Troubleshooting
204
+
205
+ **Quick Kitty Config**:
206
+ Modify Claude Code tab in `/home/eric/kitty/configs/[site].conf`:
207
+ ```conf
208
+ launch bash -c "export WP_LOCAL_SITE='UUID'; exec bash"
209
+ ```
210
+
211
+ ## Integration
212
+
213
+ **With php-fp-wordpress**:
214
+ - Test plugins during development
215
+ - Verify security functions
216
+ - Check database operations
217
+
218
+ **With js-fp-wordpress**:
219
+ - Test script enqueuing
220
+ - Verify AJAX endpoints
221
+ - Check jQuery availability
222
+
223
+ Example workflow:
224
+ ```bash
225
+ # 1. Develop plugin with php-fp-wordpress patterns
226
+ # 2. Test with wp-local
227
+ wpl plugin activate my-new-plugin
228
+ wpl eval "var_dump(current_user_can('edit_posts'));"
229
+ ```
230
+
231
+ ## Why This Approach?
232
+
233
+ **Problem**: Local WP environment breaks MCP servers when sourced in main session.
234
+
235
+ **Solution**: Bash subprocess isolation:
236
+ - Main session stays clean → MCPs work
237
+ - Each wp command gets proper environment → wp works
238
+ - No persistent environment pollution
239
+ - Simple, native Unix pattern
240
+
241
+ ## Quality Gates
242
+
243
+ Before running destructive commands:
244
+ - ✅ Correct site (.wp-local points to intended site)
245
+ - ✅ Backup if needed (database modifications)
246
+ - ✅ Site running (Local WP app)
@@ -0,0 +1,198 @@
1
+ # WP-Local Configuration Guide
2
+
3
+ ## Recommended: Kitty Terminal Integration
4
+
5
+ ### 1. Modify Kitty Configs
6
+
7
+ Update your site-specific Kitty configs to set `$WP_LOCAL_SITE` for Claude Code tab.
8
+
9
+ **File**: `/home/eric/kitty/configs/imanetwork.conf`
10
+
11
+ **Before**:
12
+ ```conf
13
+ # Claude Code tab (PRIMARY)
14
+ new_tab "Claude Code"
15
+ cd /home/eric/Local Sites/imanetwork/app/public
16
+ layout tall
17
+ launch bash -c "source ~/kitty/load-localwp-env.sh imanetwork; exec bash"
18
+ ```
19
+
20
+ **After**:
21
+ ```conf
22
+ # Claude Code tab (PRIMARY) - Clean env for MCPs + WP_LOCAL_SITE for wp-local
23
+ new_tab "Claude Code"
24
+ cd /home/eric/Local Sites/imanetwork/app/public
25
+ layout tall
26
+ launch bash -c "export WP_LOCAL_SITE='-hJRW0lQL'; exec bash"
27
+ ```
28
+
29
+ **Why this works:**
30
+ - Claude Code tab has clean environment → MCP servers work
31
+ - Claude Code tab has `$WP_LOCAL_SITE` set → wp-local skill finds the site
32
+ - Other tabs (WP CLI, Development, etc.) keep full Local WP environment → direct wp works
33
+
34
+ ### 2. Site UUID Mapping
35
+
36
+ Your existing sites:
37
+ ```
38
+ -hJRW0lQL → imanetwork
39
+ JfZ8r8eL0 → imabloglc
40
+ kHOz3MCik → flcccjournal
41
+ klZPACFw2 → kornfeld-backup-2025-10-13
42
+ VpVdumzlE → kornfeld2-prod
43
+ 19efkkzWB → journal-back-2025-10-13
44
+ ```
45
+
46
+ Update each Kitty config accordingly.
47
+
48
+ ### 3. Reload Kitty
49
+
50
+ After updating configs:
51
+ 1. Close all Kitty windows
52
+ 2. Reopen Kitty with site-specific config: `kitty --session ~/kitty/configs/imanetwork.conf`
53
+ 3. Claude Code tab should have `$WP_LOCAL_SITE` set, verify with: `echo $WP_LOCAL_SITE`
54
+
55
+ ## Alternative: `.wp-local` File (Project-Specific)
56
+
57
+ ### 1. Create `.wp-local` File
58
+
59
+ In your WordPress project root:
60
+ ```bash
61
+ echo "19efkkzWB" > .wp-local
62
+ ```
63
+
64
+ Add to `.gitignore`:
65
+ ```bash
66
+ echo ".wp-local" >> .gitignore
67
+ ```
68
+
69
+ ### 2. Finding Site UUIDs
70
+
71
+ **List all sites**:
72
+ ```bash
73
+ ls ~/.config/Local/ssh-entry/*.sh
74
+ ```
75
+
76
+ **Map UUIDs to site names**:
77
+ ```bash
78
+ for f in ~/.config/Local/ssh-entry/*.sh; do
79
+ uuid=$(basename "$f" .sh)
80
+ site=$(grep "echo -n -e" "$f" | sed 's/.*0;//' | sed 's/ Shell.*//')
81
+ echo "$uuid -> $site"
82
+ done
83
+ ```
84
+
85
+ **Output** (your sites):
86
+ ```
87
+ 19efkkzWB -> journal-back-2025-10-13
88
+ -hJRW0lQL -> imanetwork
89
+ JfZ8r8eL0 -> imabloglc
90
+ kHOz3MCik -> flcccjournal
91
+ klZPACFw2 -> kornfeld-backup-2025-10-13
92
+ VpVdumzlE -> kornfeld2-prod
93
+ ```
94
+
95
+ ### 3. Optional: Friendly Name Mapping
96
+
97
+ Create `~/.claude/wp-local-sites.json`:
98
+ ```json
99
+ {
100
+ "journal-back": "19efkkzWB",
101
+ "imanetwork": "-hJRW0lQL",
102
+ "imabloglc": "JfZ8r8eL0",
103
+ "flcccjournal": "kHOz3MCik",
104
+ "kornfeld-backup": "klZPACFw2",
105
+ "kornfeld2-prod": "VpVdumzlE"
106
+ }
107
+ ```
108
+
109
+ Then use friendly names in `.wp-local`:
110
+ ```bash
111
+ echo "journal-back" > .wp-local
112
+ ```
113
+
114
+ ### 4. Shell Alias Setup
115
+
116
+ Add to `~/.bashrc` or `~/.zshrc`:
117
+ ```bash
118
+ alias wpl='bash ~/.claude/skills/wp-local/scripts/wp-local.sh'
119
+ ```
120
+
121
+ Reload shell:
122
+ ```bash
123
+ source ~/.bashrc # or source ~/.zshrc
124
+ ```
125
+
126
+ **Usage**:
127
+ ```bash
128
+ wpl plugin list
129
+ wpl db query "SELECT * FROM wp_posts LIMIT 5"
130
+ ```
131
+
132
+ ## Environment Variable Fallback
133
+
134
+ Alternative to `.wp-local` file:
135
+ ```bash
136
+ export WP_LOCAL_SITE="19efkkzWB"
137
+ ```
138
+
139
+ Or per-command:
140
+ ```bash
141
+ WP_LOCAL_SITE="19efkkzWB" wpl plugin list
142
+ ```
143
+
144
+ ## Multi-Project Workflow
145
+
146
+ Each project has its own `.wp-local`:
147
+ ```
148
+ ~/projects/client-a/
149
+ .wp-local (contains: imanetwork)
150
+
151
+ ~/projects/client-b/
152
+ .wp-local (contains: kornfeld2-prod)
153
+ ```
154
+
155
+ wp-local automatically finds correct `.wp-local` by searching upward from current directory.
156
+
157
+ ## Troubleshooting
158
+
159
+ ### Error: "No site configured"
160
+
161
+ **Cause**: No `.wp-local` file found and `$WP_LOCAL_SITE` not set.
162
+
163
+ **Fix**: Create `.wp-local` in project root:
164
+ ```bash
165
+ echo "19efkkzWB" > .wp-local
166
+ ```
167
+
168
+ ### Error: "Local WP environment not found"
169
+
170
+ **Cause**: UUID in `.wp-local` doesn't match any script in `~/.config/Local/ssh-entry/`.
171
+
172
+ **Fix**:
173
+ 1. Check available UUIDs:
174
+ ```bash
175
+ ls ~/.config/Local/ssh-entry/*.sh
176
+ ```
177
+ 2. Update `.wp-local` with correct UUID
178
+
179
+ ### Error: "wp: command not found"
180
+
181
+ **Cause**: Local WP environment not sourcing correctly, or site not running.
182
+
183
+ **Fix**:
184
+ 1. Verify site is running in Local WP app
185
+ 2. Test manual source:
186
+ ```bash
187
+ source ~/.config/Local/ssh-entry/19efkkzWB.sh
188
+ wp --version
189
+ ```
190
+
191
+ ### Wrong site being used
192
+
193
+ **Cause**: `.wp-local` file in parent directory overriding.
194
+
195
+ **Fix**: Check for `.wp-local` files in parent directories:
196
+ ```bash
197
+ find ~ -name ".wp-local" -type f
198
+ ```