chore: document useful git commands to avoid any DCO trouble
Signed-off-by: Himanshu Mishra <himanshu@orkohunter.net>
This commit is contained in:
@@ -96,6 +96,12 @@ Awesome commit message
|
||||
Signed-off-by: Jane Smith jane.smith@example.com
|
||||
```
|
||||
|
||||
- In case you forgot to add it to the most recent commit, use `git commit --amend --signoff`
|
||||
- In case you forgot to add it to the last N commits in your branch, use `git rebase --signoff HEAD~N` and replace N with the number of new commits you created in your branch.
|
||||
- If you have a very deep branch with a lot of commits, run `git rebase -i --signoff $(git merge-base -a master HEAD)`, double check to make sense of the commits (keep all lines as `pick`) and save and close the editor. This should bulk sign all the commits in your PR. Do be careful though. If you have a complex flow with a lot of branching and re-merging of work branches and stuff, merge-base may not be the right solution for you.
|
||||
|
||||
Note: If you have already pushed you branch to a remote, you might have to force push: `git push -f` after the rebase.
|
||||
|
||||
## Creating Changesets
|
||||
|
||||
We use [changesets](https://github.com/atlassian/changesets) to help us prepare releases. They help us make sure that every package affected by a change gets a proper version number and an entry in its `CHANGELOG.md`. To make the process of generating releases easy, it helps when contributors include changesets with their pull requests.
|
||||
|
||||
Reference in New Issue
Block a user