Thank you for your interest in contributing to CPoE! This document provides guidelines and instructions for contributing.
This project adheres to a Code of Conduct. By participating, you are expected to uphold this code.
- Check existing issues before creating a new one
- Use issue templates when available
- Include reproduction steps, expected vs actual behavior
- For security vulnerabilities, see SECURITY.md
-
Prerequisites
- Rust 1.75 or later (stable toolchain)
- Cargo (included with Rust)
- Pre-commit (recommended)
- System dependencies (e.g., OpenSSL headers,
tpm2-tss-devon Linux)
-
Clone and Setup
git clone https://github.com/writerslogic/writersproof-cli.git cd writerslogic -
Install Pre-commit Hooks
pre-commit install
-
Run Tests
cargo test --all-features
-
Create a Feature Branch
git checkout -b feat/your-feature-name
-
Follow Commit Conventions
feat(scope): add new feature fix(scope): fix bug description docs(scope): update documentation refactor(scope): code refactoring test(scope): add or update tests -
Write Tests
- Aim for high coverage on new code
- Include unit and integration tests
- Test edge cases and error conditions
-
Run All Checks
cargo fmt --all -- --check # Check formatting cargo clippy --all-targets --all-features -- -D warnings # Linting cargo test --all-features # Run all tests
-
Submit Pull Request
- Fill out PR template completely
- Link related issues
- Ensure CI passes
- Follow standard Rust conventions (
rustfmt, idiomatic Rust) - Use meaningful names for variables and functions
- Document exported functions and types with doc comments (
///) - Keep functions focused and reasonably sized
Extra care is required for cryptographic code:
- No Custom Primitives: Use established crates like
sha2,ed25519-dalek,hmac. - Document Assumptions: Security assumptions and threat models
- Constant-Time Operations: Use constant-time comparison crates/functions for secrets
- Review Required: Crypto changes require security-experienced maintainer review
- Update README.md for user-facing changes
- Update inline docs for API changes
- Add examples for new features
- Keep specs in sync with implementation
- PRs require at least one maintainer approval
- All CI checks must pass
- Squash commits when merging
- Delete branch after merge
Releases are managed by maintainers:
- Semantic versioning (MAJOR.MINOR.PATCH)
- Github Actions /
cargo-distfor builds - SLSA provenance for supply chain security
- SBOM generation for compliance
- GitHub Discussions
- Documentation in writerslogic-docs
- Test files for usage examples
By contributing to CPoE, you agree that:
-
License Grant: Your contributions will be licensed under the Apache License 2.0, the same license as the project.
-
Patent Grant: You grant Writerslogic Inc. a perpetual, worldwide, royalty-free license to use any patent claims you may have that are necessarily infringed by your contribution.
-
Originality: Your contributions are your original work and you have the right to grant these licenses.
-
Patent Notice: This project is the subject of USPTO Patent Application No. 19/460,364. See the LICENSE file for complete terms.
For questions about the contributor agreement, contact: admin@writerslogic.com