aboutsummaryrefslogtreecommitdiffstats
path: root/CONTRIBUTING.md
diff options
context:
space:
mode:
Diffstat (limited to 'CONTRIBUTING.md')
-rw-r--r--CONTRIBUTING.md64
1 files changed, 64 insertions, 0 deletions
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 80ce27e..627bce2 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -18,6 +18,67 @@ specific questions and discussions should also be submitted there.
For help sending patches, please consult [git-send-email.io], or feel free to
ask for help in [~tobyvin/projectr-discuss@lists.sr.ht].
+### Style
+
+All changes are automatically verified by CI to conform to its rustfmt
+guidelines. If a CI build is failing because of formatting issues, you can
+install rustfmt using `rustup component add rustfmt` and then format all code
+using `cargo fmt`.
+
+Unless otherwise specified, this project follows the [Rust compiler's style
+guidelines].
+
+All comments should be fully punctuated with a trailing period. This applies
+both to regular and documentation comments.
+
+### Documentation
+
+Code should be documented where appropriate. The existing code can be used as a
+guidance here and the general `rustfmt` rules can be followed for formatting.
+
+Additionally, changes which have a direct effect on the user (opposed to things
+like code refactorings or documentation/tests) should be documented in the
+`CHANGELOG.md` file. The existing entries should be used as a style guideline.
+The change log should be used to document changes from a user-perspective,
+instead of explaining the technical background (like commit messages). More
+information about the change log format can be found [Keep a Changelog].
+
+## Release
+
+This procedure assumes the changes have been committed and the `main` branch has
+been checked out.
+
+1. Bump the version. The version to bump should be determined using the changes
+ made, in accordance with [SemVer].
+
+```console
+cargo xtask bump minor
+```
+
+1. Create a release commit
+
+```console
+git commit -m 'chore: release projectr version v0.5.0'
+```
+
+1. Create a tag for the release commit
+
+```console
+git shortlog v0.4.1..HEAD | git tag -s v0.5.0 --file -
+```
+
+1. Push the git refs
+
+```console
+git push --follow-tags
+```
+
+1. Publish the crate to [crates.io]
+
+```console
+cargo publish
+```
+
## Conduct
projectr and related community should follow the [Rust Code of Conduct]. For any
@@ -32,3 +93,6 @@ questions or issues related to please submit a post on the
https://lists.sr.ht/~tobyvin/projectr-devel
[git-send-email.io]: https://git-send-email.io
[Rust Code of Conduct]: https://www.rust-lang.org/policies/code-of-conduct
+[Rust compiler's style guidelines]: https://rust-lang.github.io/api-guidelines
+[Keep a Changelog]: https://keepachangelog.com
+[SemVer]: https://semver.org/