gitbot-assistant
v1.0.0
Published
Professional Git workflow automation powered by AI. Streamline your development process with natural language commands and intelligent automation.
Maintainers
Readme
GitBot Assistant
Professional Git workflow automation powered by AI. Streamline your development process with natural language commands and intelligent automation.
🚀 Features
- Natural Language Commands - Use plain English to interact with Git
- AI-Powered Automation - Leverage advanced AI for smart decision-making
- Repository Management - Create and manage GitHub repositories with ease
- Workflow Automation - Automate repetitive tasks and streamline development
- Security & Backup - Built-in safety features and automatic backup creation
- Multi-Provider Support - Support for OpenAI GPT and Anthropic Claude
📦 Installation
npm install -g gitbot-assistant🎯 Quick Start
Initialize Configuration
gitbot initAuthenticate with GitHub
gitbot auth githubStart Using Natural Language Commands
gitbot "push my changes to main" gitbot "create a new branch called feature-x" gitbot "commit with message 'fix bug'"
📖 Usage
Natural Language Commands
GitBot Assistant understands natural language commands:
# Push changes
gitbot "push my changes to main"
gitbot "push with commit message 'update feature'"
gitbot "force push to main"
# Branch management
gitbot "create a new branch called feature-x"
gitbot "switch to main branch"
gitbot "list all branches"
# Commit operations
gitbot "commit with message 'fix bug'"
gitbot "commit all changes"
gitbot "revert last commit"
# Repository management
gitbot "create a new private repository called my-project"
gitbot "list my repositories"Traditional Commands
You can also use traditional command syntax:
# Repository management
gitbot repo create my-project --private
gitbot repo list --type=owner
# Git operations
gitbot git status
gitbot git add .
gitbot git commit -m "update"
# AI-powered features
gitbot generate-commit-message
gitbot generate-gitignore "Node.js project with TypeScript"
gitbot switch-ai-provider anthropic⚙️ Configuration
Initial Setup
Run the initialization command to set up your configuration:
gitbot initThis will guide you through:
- AI provider selection (OpenAI or Anthropic)
- API key configuration
- GitHub authentication setup
Configuration Management
# View current configuration
gitbot config --show
# Reset configuration
gitbot config --reset
# Update AI provider
gitbot config --ai-provider openai
gitbot config --ai-provider anthropic
# Update API key
gitbot config --api-key YOUR_API_KEY🔧 Commands Reference
Core Commands
| Command | Description |
|---------|-------------|
| gitbot init | Initialize GitBot Assistant configuration |
| gitbot config [options] | Manage configuration settings |
| gitbot auth <provider> | Authenticate with external services |
| gitbot logout | Clear stored authentication tokens |
Repository Commands
| Command | Description |
|---------|-------------|
| gitbot repo create <name> | Create a new GitHub repository |
| gitbot repo list | List your GitHub repositories |
| gitbot repo create <name> --private | Create a private repository |
| gitbot repo create <name> --description "desc" | Create repository with description |
Git Operations
| Command | Description |
|---------|-------------|
| gitbot git status | Show Git status |
| gitbot git add <files> | Stage files |
| gitbot git commit -m "message" | Commit changes |
| gitbot git push | Push changes |
AI-Powered Features
| Command | Description |
|---------|-------------|
| gitbot generate-commit-message | Generate commit message from changes |
| gitbot generate-gitignore <description> | Generate .gitignore file |
| gitbot switch-ai-provider <provider> | Switch between AI providers |
💡 Examples
Complete Development Workflow
# 1. Create a new feature branch
gitbot "create a new branch called feature-user-auth"
# 2. Make changes and commit
gitbot "commit with message 'add user authentication'"
# 3. Push changes
gitbot "push my changes to feature-user-auth"
# 4. Create pull request
gitbot "create merge request from feature-user-auth to main"Repository Creation
# Create a new private repository
gitbot "create a new private repository called my-secret-project"
# Create with description
gitbot repo create my-project --description "My awesome project"Advanced Operations
# Force push with backup
gitbot "force push to main with backup branch creation"
# Generate commit message from diff
gitbot generate-commit-message
# Generate .gitignore for specific project
gitbot generate-gitignore "React TypeScript project with Vite"🔐 Authentication
GitHub Authentication
Run the authentication command:
gitbot auth githubFollow the browser prompts to authorize GitBot Assistant
Your GitHub token will be securely stored for future use
AI Provider Setup
You'll need an API key from either OpenAI or Anthropic:
- OpenAI: Get your API key from OpenAI Platform
- Anthropic: Get your API key from Anthropic Console
🛠️ Development
Prerequisites
- Node.js 18+
- Git
- GitHub Account
- AI Provider API Key
Local Development
# Clone the repository
git clone https://github.com/yourusername/gitbot-assistant.git
cd gitbot-assistant
# Install dependencies
npm install
# Link for local development
npm link
# Run in development mode
npm run devTesting
# Run tests
npm test
# Run linting
npm run lint
# Format code
npm run format📁 Project Structure
gitbot-assistant/
├── bin/
│ └── gitbot.js # CLI entry point
├── src/
│ ├── services/ # Core services
│ ├── utils/ # Utility functions
│ └── server/ # Authentication server
├── commands/ # Command handlers
├── docs/ # Documentation
└── package.json🤝 Contributing
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
📄 License
This project is licensed under the MIT License - see the LICENSE file for details.
🆘 Support
- Documentation: Full Documentation
- Issues: GitHub Issues
- Discussions: GitHub Discussions
🙏 Acknowledgments
- Built with ❤️ for the developer community
- Powered by OpenAI GPT and Anthropic Claude
- Inspired by the need for better Git workflow automation
Made with ❤️ by [Your Name]
