myaidev-method 0.2.5 → 0.2.6

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 (55) hide show
  1. package/USER_GUIDE.md +389 -8
  2. package/bin/cli.js +161 -70
  3. package/package.json +1 -1
  4. package/src/lib/ascii-banner.js +100 -0
  5. package/src/templates/claude/commands/myai-deploy-dev.md +500 -0
  6. package/src/templates/claude/commands/myai-deploy-prod.md +837 -0
  7. package/src/templates/claude/commands/myai-deploy-staging.md +331 -0
  8. package/src/templates/claude/commands/myai-git-hotfix.md +957 -0
  9. package/src/templates/claude/commands/myai-git-pr.md +200 -0
  10. package/src/templates/claude/commands/myai-git-release.md +806 -0
  11. package/src/templates/claude/commands/myai-git-sync.md +796 -0
  12. package/src/templates/codex/commands/myai-astro-publish.md +51 -0
  13. package/src/templates/codex/commands/myai-configure.md +185 -0
  14. package/src/templates/codex/commands/myai-content-writer.md +73 -0
  15. package/src/templates/codex/commands/myai-coolify-deploy.md +159 -0
  16. package/src/templates/codex/commands/myai-deploy-dev.md +379 -0
  17. package/src/templates/codex/commands/myai-deploy-prod.md +431 -0
  18. package/src/templates/codex/commands/myai-deploy-staging.md +275 -0
  19. package/src/templates/codex/commands/myai-dev-architect.md +69 -0
  20. package/src/templates/codex/commands/myai-dev-code.md +82 -0
  21. package/src/templates/codex/commands/myai-dev-docs.md +83 -0
  22. package/src/templates/codex/commands/myai-dev-review.md +85 -0
  23. package/src/templates/codex/commands/myai-dev-test.md +84 -0
  24. package/src/templates/codex/commands/myai-docusaurus-publish.md +42 -0
  25. package/src/templates/codex/commands/myai-git-hotfix.md +512 -0
  26. package/src/templates/codex/commands/myai-git-pr.md +196 -0
  27. package/src/templates/codex/commands/myai-git-release.md +516 -0
  28. package/src/templates/codex/commands/myai-git-sync.md +517 -0
  29. package/src/templates/codex/commands/myai-mintlify-publish.md +42 -0
  30. package/src/templates/codex/commands/myai-payloadcms-publish.md +42 -0
  31. package/src/templates/codex/commands/myai-sparc-workflow.md +185 -0
  32. package/src/templates/codex/commands/myai-wordpress-admin.md +143 -0
  33. package/src/templates/codex/commands/myai-wordpress-publish.md +66 -0
  34. package/src/templates/gemini/commands/myai-astro-publish.toml +76 -0
  35. package/src/templates/gemini/commands/myai-configure.toml +188 -0
  36. package/src/templates/gemini/commands/myai-content-writer.toml +76 -0
  37. package/src/templates/gemini/commands/myai-coolify-deploy.toml +138 -0
  38. package/src/templates/gemini/commands/myai-deploy-dev.toml +379 -0
  39. package/src/templates/gemini/commands/myai-deploy-prod.toml +438 -0
  40. package/src/templates/gemini/commands/myai-deploy-staging.toml +275 -0
  41. package/src/templates/gemini/commands/myai-dev-architect.toml +64 -0
  42. package/src/templates/gemini/commands/myai-dev-code.toml +75 -0
  43. package/src/templates/gemini/commands/myai-dev-docs.toml +76 -0
  44. package/src/templates/gemini/commands/myai-dev-review.toml +78 -0
  45. package/src/templates/gemini/commands/myai-dev-test.toml +77 -0
  46. package/src/templates/gemini/commands/myai-docusaurus-publish.toml +63 -0
  47. package/src/templates/gemini/commands/myai-git-hotfix.toml +953 -0
  48. package/src/templates/gemini/commands/myai-git-pr.toml +196 -0
  49. package/src/templates/gemini/commands/myai-git-release.toml +802 -0
  50. package/src/templates/gemini/commands/myai-git-sync.toml +792 -0
  51. package/src/templates/gemini/commands/myai-mintlify-publish.toml +67 -0
  52. package/src/templates/gemini/commands/myai-payloadcms-publish.toml +59 -0
  53. package/src/templates/gemini/commands/myai-sparc-workflow.toml +47 -0
  54. package/src/templates/gemini/commands/myai-wordpress-admin.toml +143 -0
  55. package/src/templates/gemini/commands/myai-wordpress-publish.toml +77 -0
@@ -0,0 +1,67 @@
1
+ prompt = """
2
+ Publish markdown/MDX content to Mintlify documentation site with automatic navigation updates: {{args}}
3
+
4
+ Invoke the Mintlify publishing agent to transform content, update mint.json, and deploy via git.
5
+
6
+ ## Task
7
+ Add content to Mintlify documentation and update navigation configuration.
8
+
9
+ ## Process
10
+
11
+ 1. **Read the markdown/MDX file** from the path provided
12
+ 2. **Validate frontmatter** for Mintlify compatibility
13
+ 3. **Copy file to docs directory**
14
+ 4. **Update mint.json navigation** if --nav-section is specified
15
+ 5. **Commit and push** via git workflow
16
+
17
+ ## Parameters
18
+
19
+ When parsing {{args}}, look for:
20
+ - File path (required): Path to markdown or MDX file
21
+ - --nav-section: Add to navigation section (e.g., "API Reference")
22
+ - --project: Mintlify project path (default: current directory)
23
+ - --branch: Git branch name (default: main)
24
+ - --no-push: Commit but don't push
25
+ - --dry-run: Validate without publishing
26
+
27
+ ## Examples
28
+
29
+ Basic publish:
30
+ ```
31
+ myai-mintlify-publish "getting-started.mdx"
32
+ ```
33
+
34
+ With navigation:
35
+ ```
36
+ myai-mintlify-publish "api-users.md" --nav-section "API Reference"
37
+ ```
38
+
39
+ Custom project:
40
+ ```
41
+ myai-mintlify-publish "guide.md" --project ~/docs --branch develop
42
+ ```
43
+
44
+ ## Prerequisites
45
+
46
+ Requires Mintlify project with:
47
+ - mint.json configuration file
48
+ - Git repository initialized
49
+ - Proper directory structure
50
+
51
+ ## Navigation Update
52
+
53
+ When --nav-section is specified:
54
+ 1. Parse mint.json
55
+ 2. Find or create navigation section
56
+ 3. Add new page reference
57
+ 4. Maintain alphabetical order (optional)
58
+ 5. Save updated mint.json
59
+
60
+ ## Git Workflow
61
+
62
+ 1. Check project status
63
+ 2. Add new file and mint.json (if updated)
64
+ 3. Commit with descriptive message
65
+ 4. Push to remote (unless --no-push)
66
+ 5. Report deployment status
67
+ """
@@ -0,0 +1,59 @@
1
+ prompt = """
2
+ Publish markdown content to PayloadCMS headless CMS: {{args}}
3
+
4
+ Invoke the PayloadCMS publishing agent to convert markdown to Lexical format and publish to your PayloadCMS instance.
5
+
6
+ ## Task
7
+ Convert and publish markdown content to PayloadCMS.
8
+
9
+ ## Process
10
+
11
+ 1. **Read the markdown file** from the path provided
12
+ 2. **Parse frontmatter** and extract metadata
13
+ 3. **Convert markdown to Lexical format** (PayloadCMS rich text format)
14
+ 4. **Load PayloadCMS configuration** from `.env`:
15
+ - PAYLOADCMS_URL
16
+ - PAYLOADCMS_API_KEY or login credentials
17
+ 5. **Create or update document** in specified collection
18
+ 6. **Report publishing status** with document ID and URL
19
+
20
+ ## Parameters
21
+
22
+ When parsing {{args}}, look for:
23
+ - File path (required): Path to markdown file
24
+ - --status: draft (default) or published
25
+ - --collection: Target collection name (default: posts)
26
+ - --id: Update existing document by ID
27
+ - --dry-run: Validate without publishing
28
+ - --verbose: Show detailed progress
29
+
30
+ ## Examples
31
+
32
+ Publish as draft:
33
+ ```
34
+ myai-payloadcms-publish "my-article.md"
35
+ ```
36
+
37
+ Publish to production:
38
+ ```
39
+ myai-payloadcms-publish "article.md" --status published --collection blog-posts
40
+ ```
41
+
42
+ Update existing:
43
+ ```
44
+ myai-payloadcms-publish "updated.md" --id 67890
45
+ ```
46
+
47
+ ## Prerequisites
48
+
49
+ Configure PayloadCMS credentials using the configure command first.
50
+
51
+ ## Output
52
+
53
+ Success message with:
54
+ - Document ID
55
+ - Collection name
56
+ - Status (draft/published)
57
+ - Admin panel URL
58
+ - Preview URL (if available)
59
+ """
@@ -0,0 +1,47 @@
1
+ prompt = """
2
+ You are the SPARC Workflow Orchestrator for systematic software development.
3
+
4
+ Execute the complete 5-phase SPARC development workflow for: {{args}}
5
+
6
+ ## SPARC Methodology
7
+
8
+ **S**pecification - Define requirements and system boundaries
9
+ **P**seudocode - Plan implementation approach
10
+ **A**rchitecture - Design system structure, APIs, and data models
11
+ **R**efinement - Implement, test, and review code quality
12
+ **C**ompletion - Document and deliver production-ready software
13
+
14
+ ## Workflow Execution
15
+
16
+ Execute all 5 phases sequentially:
17
+
18
+ ### Phase 1: Architecture (🏗️)
19
+ Design system architecture, API specifications, data models, and technology stack.
20
+ Output: `.myaidev-method/sparc/architecture.md`
21
+
22
+ ### Phase 2: Implementation (💻)
23
+ Implement production-ready code following SOLID principles and Clean Code standards.
24
+ Output: `.myaidev-method/sparc/code-output/`
25
+
26
+ ### Phase 3: Testing (🧪)
27
+ Create comprehensive test suites with 80%+ critical path coverage.
28
+ Output: `.myaidev-method/sparc/test-results/`
29
+
30
+ ### Phase 4: Review (👁️)
31
+ Analyze code quality, security (OWASP Top 10), and performance.
32
+ Output: `.myaidev-method/sparc/review-report.md`
33
+
34
+ ### Phase 5: Documentation (📚)
35
+ Generate API docs, user guides, and architecture documentation.
36
+ Output: `.myaidev-method/sparc/documentation/`
37
+
38
+ ## Quality Standards
39
+
40
+ - **SOLID Principles**: Single Responsibility, Open/Closed, Liskov Substitution, Interface Segregation, Dependency Inversion
41
+ - **Clean Code**: DRY, KISS, YAGNI
42
+ - **Security**: OWASP Top 10 compliance
43
+ - **Testing**: 80%+ critical path coverage, 60%+ overall
44
+ - **Performance**: <200ms API responses, <50ms database queries
45
+
46
+ Execute the complete workflow and provide comprehensive outputs for each phase.
47
+ """
@@ -0,0 +1,143 @@
1
+ prompt = """
2
+ Launch the WordPress administrator for comprehensive site management, security analysis, and performance optimization: {{args}}
3
+
4
+ Execute WordPress administration operations based on the specified action.
5
+
6
+ ## Available Operations
7
+
8
+ ### Security Operations
9
+ - `security-scan` - Comprehensive security assessment and vulnerability check
10
+ - `malware-check` - Scan for malicious code and suspicious files
11
+ - `user-audit` - Review user accounts, roles, and permissions
12
+ - `plugin-security` - Check plugins and themes for known vulnerabilities
13
+ - `ssl-check` - Verify SSL/TLS certificate and security configuration
14
+ - `file-permissions` - Audit file and directory permissions
15
+
16
+ ### Performance Operations
17
+ - `speed-test` - Analyze site performance and Core Web Vitals
18
+ - `database-optimize` - Clean and optimize WordPress database
19
+ - `cache-setup` - Configure and optimize caching strategies
20
+ - `image-optimize` - Analyze and optimize media files
21
+ - `resource-monitor` - Check server resource usage and optimization
22
+
23
+ ### Health Operations
24
+ - `health-check` - Comprehensive WordPress site health assessment
25
+ - `error-analysis` - Review and analyze error logs
26
+ - `uptime-check` - Monitor site availability and response times
27
+ - `backup-verify` - Validate backup integrity and restore capabilities
28
+ - `update-check` - Check for WordPress, plugin, and theme updates
29
+
30
+ ### Administration Operations
31
+ - `user-manage` - User and role management operations
32
+ - `plugin-manage` - Plugin installation, updates, and management
33
+ - `content-cleanup` - Remove spam, unused content, and optimize database
34
+ - `settings-optimize` - Configure optimal WordPress settings
35
+ - `staging-deploy` - Manage staging environment operations
36
+
37
+ ## Usage Examples
38
+
39
+ ### Security Assessment
40
+ ```
41
+ myai-wordpress-admin security-scan
42
+ myai-wordpress-admin malware-check
43
+ myai-wordpress-admin user-audit --role administrator
44
+ ```
45
+
46
+ ### Performance Optimization
47
+ ```
48
+ myai-wordpress-admin speed-test --detailed
49
+ myai-wordpress-admin database-optimize --cleanup-revisions
50
+ myai-wordpress-admin cache-setup --type redis
51
+ ```
52
+
53
+ ### Site Health Monitoring
54
+ ```
55
+ myai-wordpress-admin health-check --comprehensive
56
+ myai-wordpress-admin error-analysis --last-24h
57
+ myai-wordpress-admin uptime-check --setup-monitoring
58
+ ```
59
+
60
+ ### Administrative Tasks
61
+ ```
62
+ myai-wordpress-admin plugin-manage --update-all --check-security
63
+ myai-wordpress-admin content-cleanup --remove-spam --optimize-db
64
+ myai-wordpress-admin settings-optimize --performance-focus
65
+ ```
66
+
67
+ ## Process Flow
68
+
69
+ 1. **Initialize WordPress Connection**
70
+ - Validate connection to WordPress
71
+ - Check SSH access if configured
72
+ - Verify administrative permissions
73
+
74
+ 2. **Execute Operation**
75
+ - Parse operation parameters from arguments
76
+ - Execute requested administrative task
77
+ - Monitor progress
78
+
79
+ 3. **Security & Safety Checks**
80
+ - Create backups before destructive operations
81
+ - Validate permissions before changes
82
+ - Log all administrative actions
83
+
84
+ 4. **Generate Report**
85
+ - Provide detailed findings and analysis
86
+ - Include actionable recommendations
87
+ - Create priority-based action items
88
+
89
+ 5. **Follow-up Actions**
90
+ - Suggest monitoring setup
91
+ - Recommend maintenance schedules
92
+ - Provide next steps guidance
93
+
94
+ ## Required Environment Variables
95
+
96
+ ```bash
97
+ WORDPRESS_URL=https://your-wordpress-site.com
98
+ WORDPRESS_USERNAME=admin-username
99
+ WORDPRESS_APP_PASSWORD=application-password
100
+
101
+ # Optional SSH access for server-level operations
102
+ SSH_HOST=server-ip-address
103
+ SSH_USERNAME=server-username
104
+ SSH_KEY_PATH=/path/to/private/key
105
+ ```
106
+
107
+ ## Safety Features
108
+
109
+ - **Backup Creation**: Automatic backup before major changes
110
+ - **Permission Validation**: Verify admin rights before operations
111
+ - **Staging Support**: Test changes in staging environment first
112
+ - **Rollback Capability**: Provide undo procedures for changes
113
+ - **Audit Logging**: Track all administrative actions
114
+
115
+ ## Output Format
116
+
117
+ Structured reports with:
118
+ - **Executive Summary**: High-level findings and status
119
+ - **Critical Issues**: Immediate attention required
120
+ - **Warnings**: Items requiring near-term resolution
121
+ - **Recommendations**: Optimization suggestions
122
+ - **Action Items**: Specific tasks with priorities
123
+ - **Technical Details**: Logs, metrics, and detailed analysis
124
+
125
+ ## Security Considerations
126
+
127
+ This command has extensive administrative capabilities. Ensure:
128
+ - Strong authentication credentials
129
+ - Limited access to authorized personnel
130
+ - Regular audit of administrative actions
131
+ - Backup verification before major changes
132
+ - Staging environment testing when possible
133
+
134
+ ## Integration Notes
135
+
136
+ - Works with WordPress REST API
137
+ - Optional SSH integration for server-level access
138
+ - Supports both managed and self-hosted WordPress
139
+ - Compatible with major security and performance plugins
140
+ - Provides recommendations for popular caching solutions
141
+
142
+ Always prioritize site security and stability. When in doubt, create backups and test in staging environments first.
143
+ """
@@ -0,0 +1,77 @@
1
+ prompt = """
2
+ Publish the specified markdown file to WordPress using the WordPress REST API: {{args}}
3
+
4
+ ## Task
5
+ Read and publish markdown content to WordPress as draft or live post.
6
+
7
+ ## Process
8
+
9
+ 1. **Read the markdown file** from the path provided in the arguments
10
+ 2. **Parse the frontmatter** to extract:
11
+ - title
12
+ - meta_description (use as excerpt)
13
+ - slug
14
+ - tags
15
+ - category
16
+ - use_gutenberg (optional, default: false)
17
+
18
+ 3. **Load WordPress configuration** from `.env` file:
19
+ - WORDPRESS_URL
20
+ - WORDPRESS_USERNAME
21
+ - WORDPRESS_APP_PASSWORD
22
+ - WORDPRESS_USE_GUTENBERG (optional, default: false)
23
+
24
+ 4. **Convert content format** if Gutenberg is enabled:
25
+ - If use_gutenberg is true or WORDPRESS_USE_GUTENBERG is true
26
+ - Convert HTML to Gutenberg block format using patterns:
27
+ * `<!-- wp:paragraph --><p>content</p><!-- /wp:paragraph -->`
28
+ * `<!-- wp:heading {"level":2} --><h2>title</h2><!-- /wp:heading -->`
29
+
30
+ 5. **Create categories and tags** if they don't exist using WordPress REST API
31
+
32
+ 6. **Publish the post** using the WordPress REST API:
33
+ - Authenticate with Basic Auth (username:app_password)
34
+ - POST to `/wp-json/wp/v2/posts`
35
+ - Include title, content, status, categories, tags
36
+
37
+ 7. **Report the result** including:
38
+ - Post ID
39
+ - Preview URL
40
+ - Edit URL in WordPress admin
41
+ - Format used (Classic or Gutenberg)
42
+
43
+ ## Parameters
44
+
45
+ When parsing {{args}}, look for:
46
+ - File path (required): Path to markdown file
47
+ - --status: draft (default), publish, pending, private
48
+ - --gutenberg: Use Gutenberg block format (default: false)
49
+ - --classic: Force classic editor format (overrides defaults)
50
+
51
+ ## Error Handling
52
+
53
+ If WordPress credentials are not configured:
54
+ - Guide user to set up environment variables
55
+ - Provide instructions for creating Application Password
56
+
57
+ If file doesn't exist or isn't readable:
58
+ - Report clear error message
59
+ - Suggest checking file path
60
+
61
+ ## Success Response
62
+
63
+ ```
64
+ ✅ Successfully published to WordPress!
65
+ - Post ID: [id]
66
+ - Status: [draft/published]
67
+ - Preview: [preview_url]
68
+ - Edit: [admin_edit_url]
69
+ ```
70
+
71
+ ## Authentication
72
+
73
+ Use WordPress REST API with Application Password authentication:
74
+ - Create Base64 encoded credentials: base64(username:app_password)
75
+ - Add Authorization header: "Basic [encoded_credentials]"
76
+ - All API calls use HTTPS
77
+ """