Thank you for your interest in contributing to ArgParser! We want to make contributing to this project as easy and transparent as possible.
- Be respectful and inclusive
- Use welcoming and inclusive language
- Be collaborative
- Focus on what is best for the community
- Show empathy towards other community members
-
Fork the repository
-
Clone your fork:
git clone https://github.com/your-username/argparser-fp.git
-
Create a new branch:
git checkout -b feature/your-feature-name
Tprefix for types (e.g.,TStringKit,TDictionary<K,V>)Iprefix for interfaces (e.g.,IDictionary<K,V>)Fprefix for private fields (e.g.,FCount,FBuckets)Aprefix for parameters in documentation (e.g.,APath,AText)- PascalCase for types, methods, and variables
- UPPERCASE for constants
- 2 spaces for indentation (no tabs)
- No space before opening parenthesis in method calls
- Space after commas in parameter lists
- Operators surrounded by spaces (
a := b + c) - Begin/end on new lines for procedures/functions
- Begin/end on same line for control structures
- Block comments for class/interface documentation
- Line comments for implementation details
- Document public methods using:
{ @description Detailed description @param ParamName Description @return Description of return value }
- Comments should explain why, not what (the code should be self-documenting)
- Public methods first, then protected, then private
- Group related methods together
- Implementation details after interface
- Local variables at the beginning of methods
- Keep methods focused and small (ideally < 50 lines)
- Use exceptions for error conditions
- Clean up resources in
finallyblocks - Provide meaningful error messages
- Use custom exception types for specific error cases
- Use clear and meaningful commit messages
- Start with a verb (Add, Fix, Update, etc.)
- Reference issues when relevant
Example:
Add string reverse function to TStringKit
- Implement string reversal functionality
- Add unit tests
- Update documentation
Fixes #123
- Add unit tests for new functionality
- Ensure all tests pass before submitting PR
- Test on Windows (minimum requirement)
- If possible, test on Linux/macOS
- Update README.md if needed
- Add/update API documentation
- Include examples for new features
- Update changelog
- Update the README.md with details of changes if needed
- Update the documentation
- Add tests for new functionality
- Ensure the test suite passes
- Update the CHANGELOG.md
- Submit a pull request
[Type] Short description
Types:
- [Feature] - New functionality
- [Fix] - Bug fixes
- [Docs] - Documentation only
- [Test] - Test-related changes
- [Refactor] - Code refactoring
- Use the issue tracker
- Describe the bug or feature request clearly
- Include code examples if relevant
- Provide system information (OS, FPC version)
- Follow the issue template
We especially welcome documentation improvements:
- Fix typos
- Add examples
- Clarify confusing sections
- Add missing documentation
- Translate documentation
Contributors will be recognized in:
- CONTRIBUTORS.md file
- Release notes
- Project documentation
By contributing, you agree that your contributions will be licensed under the MIT License.