Thank you for your interest in contributing to the Gitopia MCP Server! This document provides guidelines and information for contributors.
- Go 1.25 or later
- Docker (for containerized development)
- Git
- A Gitopia wallet with mnemonic for testing
-
Clone the repository
git clone https://github.com/gitopia/gitopia-mcp-server.git cd gitopia-mcp-server -
Install dependencies
go mod download
-
Set up environment
cp env.example .env # Edit .env with your configuration -
Run tests
go test ./...
- Check existing issues before creating new ones
- Use clear, descriptive titles
- Provide detailed descriptions with context
- Add appropriate labels and milestones
feature/description- New featuresfix/description- Bug fixesdocs/description- Documentation updatesrefactor/description- Code refactoring
Follow Conventional Commits:
type(scope): description
feat(api): add new repository listing endpoint
fix(auth): resolve wallet authentication issue
docs(readme): update installation instructions
- Create detailed PR descriptions
- Link related issues
- Include testing instructions
- Ensure CI passes
- Request appropriate reviewers
- Follow Effective Go
- Use
gofmtfor formatting - Run
golangci-lintfor linting - Write comprehensive tests
- Unit tests for all new functionality
- Integration tests for API endpoints
- Mock external dependencies
- Maintain >80% code coverage
- Update README.md for user-facing changes
- Add inline comments for complex logic
- Update API documentation
- Include examples where helpful
├── cmd/ # Application entry points
├── internal/ # Internal packages
│ ├── config/ # Configuration management
│ ├── handler/ # MCP tool handlers
│ ├── gitopia/ # Gitopia API integration
│ └── ...
├── docs/ # Documentation
├── .github/ # GitHub workflows
└── ...
# Run all tests
go test ./...
# Run with coverage
go test -cover ./...
# Run specific package
go test ./internal/handler# Set up test environment
export GITOPIA_MNEMONIC="your test mnemonic"
export GITOPIA_GRPC_ENDPOINT="gitopia-grpc.polkachu.com:11390"
# Run integration tests
go test -tags=integration ./...go build -o bin/gitopia-mcp-server ./cmd/serverdocker build -t gitopia-mcp-server:latest .- Update CHANGELOG.md
- Create release PR
- Tag release after merge
- GitHub Actions handles Docker image publishing
- Issues: Create GitHub issues for bugs and feature requests
- Discussions: Use GitHub Discussions for questions and ideas
- Documentation: Check the
docs/directory for detailed guides
This project follows the Contributor Covenant Code of Conduct. Please be respectful and inclusive in all interactions.
By contributing to this project, you agree that your contributions will be licensed under the MIT License.