Thank you for your interest in contributing to gottp! This guide will help you get started.
- Fork the repository
- Clone your fork:
git clone https://github.com/<your-username>/gottp.git - Create a feature branch:
git checkout -b feature/my-feature - Make your changes
- Push and open a pull request
- Go 1.21 or later
- Make
make build # Build to bin/gottp
make run # Build and run
make test # Run all tests
make lint # Run linter
make test-race # Run tests with race detector
make test-cover # Generate coverage reportgo test ./internal/protocol/http/ -run TestClient_GETinternal/app/— Root Bubble Tea model and key handlinginternal/ui/— Panels, components, themes, layoutinternal/protocol/— HTTP, GraphQL, WebSocket, gRPC clientsinternal/core/— Collection, environment, history, stateinternal/export/— Export formats and code generationinternal/import/— Import format detection and parsersinternal/runner/— Headless CLI runnerinternal/scripting/— JavaScript scripting engineinternal/mock/— Mock HTTP server
- Follow standard Go conventions (
gofmt,go vet) - Run
make lintbefore submitting - Value receivers for
Update()andView(), pointer receivers for mutating methods - Sub-components return
(Model, Cmd)fromUpdate, nottea.Model
- Use clear, descriptive commit messages
- Prefix with type:
feat:,fix:,docs:,test:,refactor:,ci:
- Keep PRs focused on a single change
- Include tests for new functionality
- Update documentation if relevant
- Ensure all tests pass:
make test - Ensure linter passes:
make lint
- Implement the
protocol.Protocolinterface ininternal/protocol/<name>/ - Register it via
registry.Register(client)inapp.New() - Add a protocol-specific form in
internal/ui/panels/editor/ - Update
LoadRequest()for auto-detection
- Update
authTypesslice ininternal/ui/panels/editor/auth_section.go - Add input fields and update
BuildAuth()/LoadAuth()/View()/maxCursor()
- Add format detection logic in
internal/import/detect.go - Create an importer in
internal/import/<format>.go - Add tests
- Use the bug report template for bugs
- Use the feature request template for new ideas
- Check existing issues before creating a new one
By contributing, you agree that your contributions will be licensed under the MIT License.