A comprehensive system for organizing, managing, and sharing AI prompts and context scripts across different companies and projects.
# Initialize AI prompts structure
~/dotfiles/scripts/ai-prompts-init.sh
# Import existing prompts (if you have any)
~/dotfiles/scripts/ai-prompts-init.sh
# Follow the prompts to import from existing directories# List all prompts
aip list # or ai-prompt list
# Search for prompts
aips "laravel" # or ai-prompt search "laravel"
# Show prompt content
ai-prompt show development/code-review
# Copy prompt to clipboard
aipc development/code-review # or ai-prompt copy development/code-review
# Add new prompt
aipa development/new-feature # or ai-prompt add development/new-feature~/ai-prompts/
├── templates/ # Reusable prompt templates
│ ├── clickup/ # ClickUp ticket management
│ ├── development/ # API endpoints, migrations
│ ├── workflows/ # Developer workflows
│ ├── testing/ # Test strategies, unit tests
│ ├── debugging/ # Bug investigation
│ ├── refactoring/ # Code refactoring plans
│ ├── reviews/ # Code review checklists
│ └── documentation/ # README, API docs
├── projects/ # Project-specific content
│ ├── shakewell/ # Shakewell project
│ ├── [project-name]/ # Other projects
│ └── template/ # Template for new projects
├── scripts/ # Helper scripts
└── .secrets/ # API keys and tokens (gitignored)
└── api-keys.env # Never committed to git
Store all sensitive data in the .secrets directory:
# Edit your API keys (never committed to git)
vim ~/ai-prompts/.secrets/api-keys.env
# Example content:
OPENAI_API_KEY=sk-...
ANTHROPIC_API_KEY=sk-ant-...
GITHUB_TOKEN=ghp_...
CLICKUP_API_KEY=pk_...# Load API keys into environment
source ~/ai-prompts/scripts/load-secrets.sh# Create project structure
mkdir -p ~/ai-prompts/projects/new-project
# Copy template
cp -r ~/ai-prompts/projects/template/* ~/ai-prompts/projects/new-project/
# Set as current project
export AI_PROMPT_PROJECT=new-project
# Edit project README
vim ~/ai-prompts/projects/new-project/README.md# Share a template to a project
ai-prompt share create-ticket.md my-project
# Share workflow to project
ai-prompt share laravel-backend-developer.md shakewell
# Copy all testing templates to project
for template in ~/ai-prompts/templates/testing/*.md; do
ai-prompt share "testing/$(basename $template)" my-project
done# Export all prompts (excludes secrets)
ai-prompt export ~/Desktop/ai-prompts-backup.tar.gz
# Export to default location
ai-prompt export# Import from backup
ai-prompt import ~/Desktop/ai-prompts-backup.tar.gz# Initialize git if not already done
cd ~/ai-prompts
git init
# Sync with git (commits and pushes changes)
ai-prompt sync
# Manual git operations
cd ~/ai-prompts
git add .
git commit -m "Update prompts"
git push- create-ticket.md - Comprehensive ticket creation template
- Bug reports, features, tasks, documentation tickets
- Acceptance criteria and priority setting
- api-endpoint.md - REST API endpoint development
- database-migration.md - Database schema changes
- Model creation, service layers, controllers
- laravel-backend-developer.md - Complete Laravel workflow
- Frontend developer workflows
- DevOps deployment workflows
- test-strategy.md - Comprehensive testing approach
- Unit test generators
- Integration test scenarios
- E2E test automation
- bug-investigation.md - Systematic bug analysis
- Performance troubleshooting
- Memory leak detection
- refactor-plan.md - Code refactoring strategy
- Technical debt reduction
- Performance optimization
- code-review.md - Code review checklist
- Architecture reviews
- Security audits
- README generators
- API documentation
- Technical specifications
- Use Clear Names:
laravel-migration-generator.mdnotlmg.md - Include Context: Add usage examples and expected inputs
- Version Control: Commit regularly with meaningful messages
- Categorize Properly: Place prompts in appropriate directories
- Document Dependencies: Note required tools or APIs
- Never Commit Secrets: Use
.secrets/directory - Use Environment Variables: Load from
api-keys.env - Gitignore Sensitive Files: Already configured
- Separate Company Data: Keep proprietary info in company folders
- Regular Backups: Export prompts periodically
- Use Common for Shared: Place reusable prompts in
common/ - Company-Specific: Keep proprietary in
companies/[name]/ - Document Context: Include company-specific context
- Share Selectively: Use
ai-prompt sharecommand - Review Before Sharing: Check for sensitive data
# Check if prompt exists
find ~/ai-prompts -name "*prompt-name*"
# List all prompts
ai-prompt list
# Search for prompt
ai-prompt search "keyword"# Fix permissions
chmod -R 755 ~/ai-prompts
chmod 600 ~/ai-prompts/.secrets/api-keys.env# Reset git if needed
cd ~/ai-prompts
git status
git reset --hard HEAD# Set default project
export AI_PROMPT_PROJECT=shakewell
# Set custom prompts directory
export AI_PROMPTS_DIR=~/custom-prompts
# Add to ~/.zshrc.local for persistence
echo "export AI_PROMPT_PROJECT=shakewell" >> ~/.zshrc.localCreate custom templates for your workflow:
# Create template
cat > ~/ai-prompts/companies/shakewell/templates/feature.md << 'EOF'
# Feature: [FEATURE_NAME]
## Context
Project: [PROJECT]
Framework: Laravel/Vue
Database: PostgreSQL
## Requirements
[Paste requirements here]
## Implementation Plan
1. Database migrations
2. Model and relationships
3. API endpoints
4. Frontend components
5. Tests
## Code Generation Request
Generate the implementation following our coding standards:
- PSR-12 for PHP
- Vue 3 Composition API
- TypeScript where applicable
- Full test coverage
EOFProcess multiple prompts:
# Copy all development prompts to company
for prompt in ~/ai-prompts/common/development/*.md; do
ai-prompt share "common/development/$(basename $prompt)" shakewell
doneUse prompts in automation:
#!/bin/bash
# load-and-execute.sh
# Load prompt
PROMPT=$(ai-prompt show development/code-review)
# Use with CLI tools
echo "$PROMPT" | some-ai-cli-tool
# Or copy to clipboard for manual use
echo "$PROMPT" | pbcopy- Follow the directory structure
- Use meaningful names
- Include usage examples
- Test prompts before committing
- Never include sensitive data
- Main README - Dotfiles documentation
- Installation Guide - Setup instructions
- Terminal Setup - Terminal configuration
Your prompts are your intellectual property. This management system is part of the dotfiles project under MIT license.