Skip to content

Latest commit

 

History

History
58 lines (36 loc) · 3.26 KB

CONTRIBUTING.md

File metadata and controls

58 lines (36 loc) · 3.26 KB

Contributing to Rerun

This is written for anyone who wants to contribute to the Rerun repository.

See also

What to contribute

You can also look at our good first issue tag.

Pull Requests

We use Trunk Based Development, which means we encourage small, short-lived branches. Open draft PR:s to get some early feedback on your work.

All PR:s are merged with Squash and Merge, meaning they all get squashed to just one commit on the main branch. This means you don't need to keep a clean commit history on your feature branches. In fact, it is preferable to add new commits to a branch rather than rebasing or squashing. For one, it makes it easier to track progress on a branch, but rebasing and force-pushing also discourages collaboration on a branch.

Our CI will run benchmarks on each merged PR. The results can be found at https://rerun-io.github.io/rerun/dev/bench/.

Structure

The main crates are found in the crates/ folder, with examples in the examples/ folder.

To get an overview of the crates, read their documentation with:

cargo doc --no-deps --open

To learn about the viewer, run:

cargo run -p rerun -- --help

Tools

We use the just command runner tool for repository automation. See here for installation instructions. To see available automations, use just --list.

We use cargo cranky and specify our clippy lints in Cranky.toml. Usage: cargo cranky.

We use cargo deny to check our dependency tree for copy-left licenses, duplicate dependencies and rustsec advisories. You can configure it in deny.toml. Usage: cargo deny check.

Configure your editor to run cargo fmt on save. Also configure it to strip trailing whitespace, and to end each file with a newline. Settings for VSCode can be found in the .vscode folder and should be applied automatically. If you are using another editor, consider adding good setting to this repository!

To check everything in one go, run ./scripts/check.sh. check.sh should ideally check approximately the same things as our CI.

Optional

You can use bacon to automatically check your code on each save. For instance, running just bacon will re-run cargo cranky each time you change a rust file. See bacon.toml for more.

Other

You can view higher log levels with export RUST_LOG=debug or export RUST_LOG=trace.