docs: Update contribution guidelines for Gerrit workflow

Change-Id: Ia06886c61fbecd885d038f7e8f1d915cd4304547
Reviewed-on: https://cl.tvl.fyi/c/depot/+/90
Reviewed-by: tazjin <mail@tazj.in>
Reviewed-by: riking <rikingcoding@gmail.com>
This commit is contained in:
Vincent Ambo 2020-06-12 03:09:54 +01:00 committed by tazjin
parent a9f3621fd7
commit cc2fe0308c

View file

@ -13,8 +13,8 @@ Contribution Guidelines
<!-- markdown-toc end --> <!-- markdown-toc end -->
This is a loose set of "guidelines" for contributing to my depot. Please note This is a loose set of "guidelines" for contributing to the depot. Please note
that I will not accept any patches that don't follow these guidelines. that we will not accept any patches that don't follow these guidelines.
Also consider the [code of conduct](/tree/docs/CODE_OF_CONDUCT.md). No really, Also consider the [code of conduct](/tree/docs/CODE_OF_CONDUCT.md). No really,
you should. you should.
@ -28,8 +28,8 @@ When adding a feature you should consider whether it is only useful for your
particular use-case or whether it is generally applicable for other users of the particular use-case or whether it is generally applicable for other users of the
project. project.
When in doubt - just ask! You can reach out to me via When in doubt - just ask! You can reach out to us at
[mail](mailto:mail@tazj.in) or on Twitter / IRC / etc. [depot@tazj.in](mailto:depot@tazj.in) or on Twitter, IRC, etc.
## Commit messages ## Commit messages
@ -57,6 +57,10 @@ Where `type` can be one of:
And `scope` should refer to some kind of logical grouping inside of the project. And `scope` should refer to some kind of logical grouping inside of the project.
It does not make sense to include the full path unless it aids in
disambiguating. For example, when changing the configuration of the host
`camden` at `//ops/nixos/camden` it is enough to write `feat(camden): ...`.
Please take a look at the existing commit log for examples. Please take a look at the existing commit log for examples.
## Commit content ## Commit content
@ -91,28 +95,31 @@ while squinting and keeping some distance from your screen ;-)
## Builds & tests ## Builds & tests
My projects are built using [Nix][] to avoid "build pollution" via the user's All projects are built using [Nix][] to avoid "build pollution" via the user's
environment. environment.
If you have Nix installed and are contributing to a project tracked in this If you have Nix installed and are contributing to a project tracked in this
repository, you can usually build the project by calling `nix-build -A repository, you can usually build the project by calling `nix-build -A
path.to.project`. path.to.project`.
For example, to build a project located at `tools/foo` you would call `nix-build For example, to build a project located at `//tools/foo` you would call
-A tools.foo` `nix-build -A tools.foo`
If the project has tests, check that they still work before submitting your If the project has tests, check that they still work before submitting your
change. change.
## Submitting patches ## Submitting changes
When making a change, please create an appropriate commit locally and send it to Development is primarily tracked at [cl.tvl.fyi](https://cl.tvl.fyi) using
me using either `git send-email` or `git format-patch`. The email address to use Gerrit. If you have an account, use the standard Gerrit workflows to submit a
for depot reviews is `depot@tazj.in`, which is a [public group][]. change.
I recognise that most people are used to a GitHub-style workflow. If you run If you do not have an account, you can alternatively submit a patch
into issues with the above but would still like to contribute, feel free to via email. Create an appropriate commit locally and send it to
reach out to me. `depot@tazj.in` using either `git send-email` or `git format-patch`.
The email address is a [public group][].
Patches submitted via email will be added to Gerrit by a contributor.
[magit]: https://magit.vc/ [magit]: https://magit.vc/
[Nix]: https://nixos.org/nix/ [Nix]: https://nixos.org/nix/