Contributing

April 10, 2026 ยท View on GitHub

Thank you for your interest in contributing to leaf.

Getting Started

  1. Fork the repository.
  2. Clone your fork:
git clone https://github.com/<your-username>/leaf.git
cd leaf
  1. Install Rust if needed:
rustup show
  1. Build the project:
cargo build
  1. Run the application:
cargo run -- README.md

Development Workflow

Before submitting a PR, run the full validation sequence:

cargo test
cargo clippy --all-targets --all-features -- -D warnings
cargo build --release

Pull Requests

  1. Create a feature branch from main.
  2. Make focused changes.
  3. Keep documentation in sync when behavior changes.
  4. Ensure all checks pass.
  5. Open a PR with a clear description of:
    • what changed;
    • why it changed;
    • how it was tested.

Commit Messages

  • Use clear, direct messages.
  • Keep the first line short.
  • Prefer the existing prefixes used in the repository when they fit.

Examples:

  • feat: custom themes
  • chore: refactor main.rs
  • fix: file picker alignment
  • docs: update README.md

Code Style

  • Follow the existing Rust style in the repository.
  • Prefer small, targeted refactors over broad rewrites.
  • Preserve the current terminal UX unless the change explicitly improves it.
  • Keep ASCII by default unless the file already uses Unicode intentionally.

Testing Notes

  • Add regression tests when fixing rendering or parsing bugs.
  • Prefer narrow, behavior-focused tests over snapshot-heavy tests.
  • If a change affects terminal layout, verify both tests and manual rendering.

Architecture

See:

Releases

Release automation lives in:

Installers live in:

Questions

Open an issue or discussion in the repository: