This guide helps Windows contributors resolve Developer Certificate of Origin (DCO) failures on their pull requests.
MisakaNet enforces the Developer Certificate of Origin (DCO) to ensure all code contributions are legally authorized. Every commit in your Pull Request must contain a Signed-off-by: line at the bottom of the commit message matching the git commit author's name and email.
If your PR shows a failed DCO check, it is usually because you didn't commit with the --signoff (or -s) flag.
To fix existing commits that failed the DCO check, open your terminal (Git Bash, Command Prompt, or PowerShell) in your repository directory and run the following commands:
If you only need to sign off your latest commit:
# Add the sign-off trailer to the last commit
git commit --amend --signoff --no-edit
# Force-push to update your Pull Request
git push --force-with-leaseIf you need to sign off multiple commits in your branch, you can perform an interactive rebase:
# Start an interactive rebase for the last N commits (replace N with your number of commits)
git rebase -i HEAD~NIn the editor that opens:
- Change
picktoedit(ore) for all the commits you need to sign off. - Save and exit the editor.
- For each commit, Git will pause. Run the following:
git commit --amend --signoff --no-edit git rebase --continue
- Once completed, force push:
git push --force-with-lease
You can configure Git on Windows to automatically sign off or template your commit messages:
Ensure your name and email are configured correctly (this email must match the one in your Signed-off-by: line):
git config --global user.name "Your Real Name"
git config --global user.email "your.email@example.com"Remember to append -s whenever you make a commit:
git commit -s -m "docs: add Windows DCO quickstart"