From 1ea0db3f37bc29d79a43ea117589ed84b64e517d Mon Sep 17 00:00:00 2001 From: woodser Date: Wed, 1 Dec 2021 13:09:07 -0500 Subject: [PATCH] add instructions to rebase and squash commits --- docs/developer-guide.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/docs/developer-guide.md b/docs/developer-guide.md index 82e2d755..6d6a2c82 100644 --- a/docs/developer-guide.md +++ b/docs/developer-guide.md @@ -34,6 +34,20 @@ Follow [instructions](https://github.com/haveno-dex/haveno-ui-poc#run-tests) to 9. Run the tests with `npm run test -- -t 'my test'` to run tests by name and `npm test` to run all tests together. Ensure all tests pass and there are no exception stacktraces in the terminals of Alice, Bob, or the arbitrator. 10. Open pull requests to the haveno and haveno-ui-poc projects for the backend and frontend implementations. +## How to rebase and squash your commits + +When submitting a pull request for review, please first rebase and squash your commits. + +1. Checkout the latest version from master, e.g.: `git checkout master && git pull upstream master` +2. Checkout your feature branch, e.g.: `git checkout your_branch` +3. Optionally make a backup branch just in case something goes wrong, e.g.: `git checkout -b your_branch_bkp && git checkout your_branch` +4. Rebase on master: `git rebase master` +5. Squash your commits: `git reset --soft ` +6. Commit your changes to a single commit: `git commit` +7. Push your local branch to your remote repository: `git push --force` + +If you have a PR open on that branch, it'll be updated automatically. + ## Trade Protocol For documentation of the trade protocol, see [trade protocol](trade_protocol/trade-protocol.pdf). \ No newline at end of file