First off, thank you for considering contributing to FreshLogger! It's people like you who make FreshLogger such a great tool.
- Fork the repository
- Clone your fork:
git clone git@github.com:YOUR_USERNAME/FreshLogger.git - Create a feature branch:
git checkout -b feature/amazing-feature - Make your changes
- Test your changes:
make enterprise-test - Commit your changes:
git commit -m 'feat: add amazing feature' - Push to your branch:
git push origin feature/amazing-feature - Open a Pull Request
We as members, contributors, and leaders pledge to make participation in our community a harassment-free experience for everyone.
Examples of behavior that contributes to a positive environment:
- Using welcoming and inclusive language
- Being respectful of differing viewpoints and experiences
- Gracefully accepting constructive criticism
- Focusing on what is best for the community
- Showing empathy towards other community members
- C++17 compatible compiler (GCC 7+, Clang 5+, MSVC 2017+)
- CMake 3.10+ or Make
- spdlog library
- Google Test (for testing)
# Using Make
make all # Build everything
make test # Run basic tests
make enterprise-test # Run all tests
# Using CMake
mkdir build && cd build
cmake ..
make
make test# Run specific test suites
make simple-test # Basic functionality tests
make unit-tests # Unit tests
make performance-tests # Performance benchmarks
make stress-tests # Stress and stability tests
make edge-case-tests # Edge case tests
# Run complete test suite
make enterprise-testWe use Conventional Commits for commit messages:
<type>[optional scope]: <description>
[optional body]
[optional footer(s)]
- feat: A new feature
- fix: A bug fix
- docs: Documentation only changes
- style: Changes that do not affect the meaning of the code
- refactor: A code change that neither fixes a bug nor adds a feature
- perf: A code change that improves performance
- test: Adding missing tests or correcting existing tests
- chore: Changes to the build process or auxiliary tools
feat: add async logging support
fix: resolve memory leak in file rotation
docs: update README with new examples
test: add performance benchmarks
chore: bump version to 1.1.0
- C++17 minimum requirement
- Use modern C++ features where appropriate
- Prefer RAII and smart pointers
- Avoid raw pointers when possible
- Throughput: >1M messages/second
- Latency: <1 μs average
- Memory: Minimal overhead
- Thread Safety: 100% thread-safe operations
- Coverage: 100% code coverage
- Performance: All performance tests must pass
- Stress: All stress tests must pass
- Edge Cases: All edge case tests must pass
TEST_F(TestClassName, TestMethodName) {
// Arrange
Logger::Config config;
config.logFilePath = "test.log";
// Act
Logger logger(config);
logger.info("test message");
// Assert
EXPECT_TRUE(std::filesystem::exists("test.log"));
}- Unit Tests: Test individual functions
- Integration Tests: Test component interactions
- Performance Tests: Test performance metrics
- Stress Tests: Test under extreme conditions
- Edge Case Tests: Test boundary conditions
- Use Doxygen-style comments for public APIs
- Include examples in comments
- Document all configuration options
- Explain complex algorithms
- Keep README.md up to date
- Document breaking changes in CHANGELOG.md
- Provide usage examples
- Include troubleshooting guides
- Patch (1.0.x): Bug fixes, no breaking changes
- Minor (1.x.0): New features, backward compatible
- Major (x.0.0): Breaking changes
- All tests pass
- Performance benchmarks meet requirements
- Documentation is up to date
- CHANGELOG.md is updated
- Version numbers are updated
- Release notes are written
- Issues: Use GitHub Issues for bug reports and feature requests
- Discussions: Use GitHub Discussions for questions and ideas
- Wiki: Check the wiki for detailed guides and examples
By contributing to FreshLogger, you agree that your contributions will be licensed under the MIT License.
Thank you for contributing to FreshLogger! 🌱✨