Transform chaotic code folders into professional, organized repositories that work seamlessly with GitHub and teams.
RepoKit automates the creation of standardized Git repositories with professional structure, worktree-based and branching workflows, and GitHub/Gitlab/etc deployment pipelines. Whether you're starting fresh or organizing existing code, RepoKit provides the structure and tools for professional development.
Before: Scattered files, no organization, deployment nightmares
After: Professional structure, team-ready, GitHub-ready, portfolio-worthy
New to RepoKit? Read Why RepoKit Exists for the complete picture.
- Universal Bootstrap System: Analyze and migrate ANY project to RepoKit structure
- Standardized Repository Structure: Consistent directory layout with standard folders
- Multi-Branch Strategy: Automatic setup of main, dev, staging, test, live, and private branches
- Worktree Management: Git worktrees for efficient branch isolation and parallel development
- Private Content Protection: Secure local-only content that never gets pushed
- GitHub/GitLab Integration: Automated repository creation and deployment
- AI Development Integration: Built-in Claude AI assistance with workflow documentation
- Template Customization: Language-specific templates (Python, JavaScript, etc.)
- Comprehensive Test Framework: Unit, integration, and end-to-end testing
- Empty Projects: Start fresh with optimal structure
- Existing Code: Preserve your files while adding RepoKit benefits
- Git Repositories: Maintain full history while upgrading workflow
- Complex Projects: Handle multi-branch, multi-contributor scenarios
- Legacy Codebases: Safe migration with conflict resolution
# Install from source
git clone https://github.com/djdarcy/git-repokit.git
cd git-repokit
# Install in development mode with all dependencies
pip install -e ".[dev]"
# Or install for regular use
pip install -e .# Basic project creation
repokit create my-awesome-project --language python
# Create and deploy to GitHub in one command
repokit create my-project --language python --publish-to github --private-repo
# Create with AI integration
repokit create my-project --ai claude --publish-to github# Analyze what RepoKit will do
repokit analyze .
# Adopt in-place with safe strategy
repokit adopt . --publish-to github --private-repo
# Migrate to new structure (creates copy)
repokit migrate ./old-project ./new-project# Create project with GitHub deployment
repokit create awesome-api \
--language python \
--description "My awesome Python API" \
--publish-to github \
--private-repo \
--ai claude# First, analyze your project
cd existing-project
repokit analyze .
# Then adopt with recommended settings
repokit adopt . \
--migration-strategy safe \
--publish-to github \
--organization my-company# Analyze complex project
repokit analyze ./legacy-app
# Adopt with careful conflict handling
repokit adopt ./legacy-app \
--strategy safe \
--branch-strategy gitflow \
--dry-run # Preview changes first# Create with custom structure
repokit create platform \
--language generic \
--directories "backend,frontend,shared,docs,infra" \
--branches "main,develop,release,hotfix" \
--publish-to githubRepoKit can analyze any project and provide migration recommendations:
repokit analyze /path/to/project
# Output includes:
# - Project type (empty, source_no_git, git_with_history, etc.)
# - Detected primary language
# - Migration complexity (low/medium/high)
# - Recommended migration strategy
# - Recommended branch strategy
# - Step-by-step migration planRepoKit supports multiple branching strategies:
private → dev → main → test → staging → live
private → dev → main
private → feature/* → develop → release/* → main
↘ ↗
hotfix/* → → → ↗
private → feature/* → main
repokit create my-project \
--branches "main,develop,qa,production" \
--worktrees "main,develop"# Store GitHub credentials (one time)
repokit store-credentials --publish-to github --token YOUR_TOKEN
# Or use environment variable
export GITHUB_TOKEN=YOUR_TOKEN# Create and deploy in one command
repokit create my-project --publish-to github --private-repo
# Deploy to organization
repokit create team-project \
--publish-to github \
--organization my-company \
--private-repoRepoKit includes Claude AI integration for enhanced development:
# Create project with AI assistance
repokit create my-project --ai claude
# This adds:
# - CLAUDE.md with project context
# - Development workflow instructions
# - Problem-solving methodology (The Process)
# - Private documentation structureRepoKit creates an organized project structure:
my-project/
├── local/ # Main repository (private branch)
│ ├── docs/ # Documentation
│ ├── tests/ # Test files
│ ├── scripts/ # Utility scripts
│ ├── private/ # Local-only content
│ │ └── claude/ # AI assistance docs
│ └── ...
├── github/ # Main branch worktree
└── dev/ # Development branch worktree
RepoKit includes a comprehensive test framework:
# Run all tests
python tests/run_tests.py
# Run specific test categories
python tests/run_tests.py --unit # Fast unit tests
python tests/run_tests.py --integration # CLI integration tests
python tests/run_tests.py --github # GitHub API tests (requires token)
# Check test environment
python tests/run_tests.py --check- Documentation Guide - Start here for navigation
- Why RepoKit Exists - Understand the problem and solution
- Adoption Guide - Step-by-step tutorials for existing projects
- Recipes and How-Tos - Copy-paste commands for common scenarios
- Branch Strategies - Branching workflows explained
- Migration Guide - Universal bootstrap scenarios
- Auth Guide - Authentication and credentials
- Workflow Guide - Development workflows
- Deployment Demo - Step-by-step deployment examples
- Test Framework - Comprehensive testing documentation
💡 Pro Tip: Start with the Documentation Guide for easier perusal and recommended reading order.
RepoKit uses hierarchical configuration:
- Default values (built-in)
- Global config (
~/.repokit/config.json) - Project config (
./.repokit.json) - Environment variables (
REPOKIT_*) - CLI arguments (highest priority)
{
"name": "my-project",
"language": "python",
"branches": ["main", "develop", "staging"],
"worktrees": ["main", "develop"],
"user": {
"name": "Your Name",
"email": "[email protected]"
},
"github": true,
"private_repo": true
}Contributions are welcome! See CONTRIBUTING.md for development setup and guidelines. Please feel free to open issues or submit pull requests.
Like the project?
This project is licensed under the MIT License - see the LICENSE file for details.
- Inspired by modern DevOps practices and GitOps workflows
- https://nvie.com/posts/a-successful-git-branching-model/
- https://trunkbaseddevelopment.com/
- https://docs.github.com/en/get-started/quickstart/github-flow
- https://martinfowler.com/articles/continuousIntegration.html
- https://www.atlassian.com/continuous-delivery
- https://www.perforce.com/blog/vcs/best-branching-strategies-high-velocity-development
- Built for developers who value consistency and automation
- Special thanks to the open-source community