Thank you for considering contributing to PortKill. This document provides guidelines and instructions for contributing to the project.
All contributors are expected to maintain professional conduct and respect for others in all project interactions.
- Fork the repository
- Clone your fork:
git clone https://github.com/your-username/portkill.git - Add upstream remote:
git remote add upstream https://github.com/mr-tanta/portkill.git - Create a feature branch:
git checkout -b feature/your-feature-name
- macOS or Linux development environment
- Bash 3.2 or later
- Git
- Make
make buildmake testWhen reporting issues, please include:
- Operating system and version
- PortKill version
- Steps to reproduce the issue
- Expected behavior
- Actual behavior
- Error messages if applicable
- Ensure your code adheres to the project style guidelines
- Add tests for new functionality
- Update documentation as needed
- Commit your changes using descriptive commit messages
- Push to your fork and submit a pull request
Use conventional commit format:
type(scope): subject
body
footer
Types:
feat: New featurefix: Bug fixdocs: Documentation changestest: Test additions or modificationsrefactor: Code refactoringperf: Performance improvementschore: Maintenance tasks
Example:
feat(cli): add interactive mode for port selection
Implements a terminal UI that allows users to select ports
from a list rather than specifying them via command line.
Closes #42
- Use ShellCheck for linting
- Follow POSIX shell conventions where possible
- Use meaningful variable names
- Add comments for complex logic
- Handle errors explicitly
- Keep documentation concise and accurate
- Include code examples where appropriate
- Update README.md for user-facing changes
- Document all public functions and APIs
All new features should include appropriate tests:
- Unit tests for individual functions
- Integration tests for command workflows
- Edge case handling
# Run unit tests
make test-unit
# Run integration tests
make test-integration
# Run all tests with coverage
make test-coverage- Update documentation for any changed functionality
- Ensure all tests pass
- Request review from maintainers
- Address review feedback
- Squash commits before merging
## Description
Brief description of the changes
## Type of Change
- [ ] Bug fix
- [ ] New feature
- [ ] Breaking change
- [ ] Documentation update
## Testing
- [ ] Tests pass locally
- [ ] New tests added
- [ ] Manual testing completed
## Checklist
- [ ] Code follows project style guidelines
- [ ] Self-review completed
- [ ] Documentation updatedportkill/
├── bin/ # Executable scripts
├── lib/ # Core functionality
├── test/ # Test suites
├── docs/ # Documentation
└── scripts/ # Build and utility scripts
Releases follow semantic versioning (MAJOR.MINOR.PATCH):
- MAJOR: Breaking changes
- MINOR: New features (backward compatible)
- PATCH: Bug fixes
For questions about contributing, please open a discussion in the GitHub repository.
By contributing to PortKill, you agree that your contributions will be licensed under the MIT License.