Thank you for considering contributing to Shepherd! This guide will help you get started.
- Fork the repository and clone your fork
- Install Rust (stable) and Node.js 20+
- Install system dependencies (Linux):
sudo apt-get install -y libwebkit2gtk-4.1-dev libappindicator3-dev librsvg2-dev patchelf - Run
npm cito install frontend dependencies
cargo build --workspace
npm run build
cargo build --manifest-path src-tauri/Cargo.toml# Rust tests
cargo test --workspace
# Frontend tests
npx vitest run
# E2E tests
npx playwright test
# Formatting
cargo fmt --all -- --check
# Linting
cargo clippy --workspace --all-targets -- -D warnings- Create a feature branch from
main - Write tests for new functionality (TDD preferred)
- Ensure all tests pass:
cargo test --workspace && npx vitest run - Run
cargo fmt --allbefore committing - Keep commits focused and well-described
- Open a PR against
mainwith a clear description
- Tests added/updated
-
cargo fmt --allpasses -
cargo clippy --workspacepasses -
cargo test --workspacepasses - Frontend tests pass (
npx vitest run)
- Follow existing patterns in the codebase
- Use
rustfmtandclippydefaults (configured inrustfmt.tomlandclippy.toml) - Prefer small, focused commits
By contributing, you agree that your contributions will be licensed under the Apache-2.0 License.