blob: a31b109b44eeee8c65530874b38fb9a8f1d2674e [file] [log] [blame] [view]
lowRISC Contributors802543a2019-08-31 12:12:56 +01001# Contributing code to the opentitan repository
2
Alex Bradburydb9c2712019-11-01 04:04:00 +00003## Contributor License Agreement
4
5Contributions to OpenTitan must be accompanied by sign-off text that indicates
6acceptance of the Contributor License Agreement (see [CLA](CLA) for full
7text), which is closely derived from the Apache Individual Contributor License
8Agreement. The sign-off text must be included once per commit, in the commit
9message. The sign-off can be automatically inserted using a command such as
10`git commit -s`, which will generate the text in the form:
Adam H. Leventhald019b9d2020-01-15 19:59:12 -080011`Signed-off-by: Random J Developer <random@developer.example.org>`
Alex Bradburydb9c2712019-11-01 04:04:00 +000012
13By adding this sign-off, you are certifying:
14
15_By signing-off on this submission, I agree to be bound by the terms of the
16Contributor License Agreement located at the root of the project repository,
17and I agree that this submission constitutes a "Contribution" under that
18Agreement._
19
20Please note that this project and any contributions to it are public and that
21a record of all contributions (including any personal information submitted
22with it, including a sign-off) is maintained indefinitely and may be
23redistributed consistent with this project or the open source license(s)
24involved.
25
lowRISC Contributors802543a2019-08-31 12:12:56 +010026## Quick guidelines
27
28* Keep a clean commit history. This means no merge commits, and no long series
29 of "fixup" patches (rebase or squash as appropriate). Structure work as a
30 series of logically ordered, atomic patches. `git rebase -i` is your friend.
Rupert Swarbrick0b6831f2020-11-30 08:15:48 +000031* Changes should be made via pull request, with review. A pull request will be
32 committed by a "committer" (an account listed in `COMMITTERS`) once it has
33 had an explicit positive review.
lowRISC Contributors802543a2019-08-31 12:12:56 +010034* When changes are restricted to a specific area, you are recommended to add a
35 tag to the beginning of the first line of the commit message in square
Rupert Swarbrick0b6831f2020-11-30 08:15:48 +000036 brackets. e.g. "[uart] Fix bug #157".
lowRISC Contributors802543a2019-08-31 12:12:56 +010037* Code review is not design review and doesn't remove the need for discussing
38 implementation options. If you would like to make a large-scale change or
39 discuss multiple implementation options, discuss on the mailing list.
40* Create pull requests from a fork rather than making new branches in
41 `github.com/lowrisc/opentitan`.
lowRISC Contributors802543a2019-08-31 12:12:56 +010042* Do not attempt to commit code with a non-Apache license without discussing
43 first.
44* If a relevant bug or tracking issue exists, reference it in the pull request
45 and commits.
Alex Bradburyc2677ea2021-05-06 11:15:26 +010046
47Please see [Contributing to
48OpenTitan](https://docs.opentitan.org/doc/project/contributing/) for more
49general guidance.