We want to make contributing to this project as easy and transparent as possible, whether it's:
We are using Github Flow, so all code changes happen through pull requests from a forked repo.
The current active branch is next
. Every branch with a fix/feature must be forked from next
.
The branch name should contain a short issue/feature description separated with hyphens (kebab-case).
For example, if the issue title is Fix functionality X in component Y
then the branch name will be something like: fix-x-in-y
.
New branch should be rebased from next
before submitting a PR in case there have been changes to avoid merge commits.
i.e. this branches state:
A---B---C fix-x-in-y
/
D---E---F---G next
| |
(F, G) changes happened after `fix-x-in-y` forked
should become this after rebase:
A'--B'--C' fix-x-in-y
/
D---E---F---G next
Commit messages should be written in a short, descriptive manner and be prefixed with tags for the change type and scope (if possible) according to the semantic commit scheme.
For example, a new change to the AIR crate might have the following message: feat(air): add constraints for the decoder
Also squash commits to logically separated, distinguishable stages to keep git log clean:
7hgf8978g9... Added A to X \
\ (squash)
gh354354gh... oops, typo --- * ---------> 9fh1f51gh7... feat(X): add A && B
/
85493g2458... Added B to X /
789fdfffdf... Fixed D in Y \
\ (squash)
787g8fgf78... blah blah --- * ---------> 4070df6f00... fix(Y): fixed D && C
/
9080gf6567... Fixed C in Y /
For documentation in the codebase, we follow the rustdoc convention with no more than 100 characters per line.
For code sections, we use code separators like the following to a width of 100 characters::
// CODE SECTION HEADER
// ================================================================================
Rustfmt and Clippy linting is included in CI pipeline. Anyways it's preferable to run linting locally before push:
cargo fix --allow-staged --allow-dirty --all-targets --all-features; cargo fmt; cargo clippy --workspace --all-targets --all-features -- -D warnings
We use semver naming convention.
next
according to the naming convention.next
.
Great Bug Reports tend to have:
In short, when you submit code changes, your submissions are understood to be under the same MIT License that covers the project. Feel free to contact the maintainers if that's a concern.