Before Making Significant Changes
If you want to make a more significant change, please first open an issue to discuss the change that you want to make. Dave Cheney gives a good rationale as to why this is important.Pull Request Checklist
All changes are made via pull requests. In your pull request, please make sure that:Tests
- All existing tests pass. You can ensure this by running
make test. - There are appropriate additional tests that demonstrate that your PR works as intended.
Documentation
- The documentation is updated, if necessary. For new features you should add an entry in
assets/chezmoi.io/docs/user-guide/and a complete description inassets/chezmoi.io/docs/reference/. - By default, chezmoi will panic if a flag is undocumented or a long help is missing for a command. You can disable this panic during development by setting the environment variable
CHEZMOIDEVtoignoreflags=1,ignorehelp=1. - Once you have documented the command and its flags, run
make generateto generate the embedded documentation.
Code Quality
- All generated files are up to date. You can ensure this by running
make generateand including any modified files in your commit. - The code is correctly formatted. You can ensure this by running
make format. - The code passes
golangci-lint. You can ensure this by runningmake lint.
Commit Messages
-
The commit messages adhere to the conventional commits specification, with the following additional requirements:
-
The first character of the commit message is uppercase, e.g:
The purpose of this is to maintain consistency in chezmoi’s release notes, which are generated directly from the commit messages.
-
The commits do not have scopes (e.g.
chore(scope): Messageis invalid).
-
The first character of the commit message is uppercase, e.g:
fix: bug fixes in chezmoi codefeat: extending an existing feature or adding a new featuredocs: adding to or updating the documentationchore: small changes, such as fixing a typo, correcting grammar (including in documentation), or anything not covered by the above
Branch Quality
- Commits are logically separate, with no merge or “fixup” commits.
- The branch applies cleanly to
master.
Code of Conduct
chezmoi follows the Contributor Covenant Code Of Conduct with the following additions for LLM (Large Language Model)-generated contributions:- Any contribution of any LLM-generated content will be rejected and result in an immediate ban for the contributor, without recourse.