Hi,
Sometimes, I forget some hg commands.
Here’s a small cheat sheet with the most used hg commands to deal with Tryton/Heptapod.
Commands
Cloning Tryton Repo:
hg clone ssh://hg@foss.heptapod.net/tryton/tryton
Updating Tryton Repo:
hg update
Listing topics:
hg topics
Create new Topic:
hg topic <topic-name>
Switching into Topic:
hg update <topic-name>
You must rebase your topic on top of default branch. Can be done with:
hg pull -u && hg update <topic> && hg rebase -d default && hg push
Seeing diff from base:
hg diff -r s0
Seeing Stack:
hg stack
Commiting first time:
hg commit -m 'your commit'
Commiting after updating patch:
hg amend
Commiting after updating patch and changing commit text:
hg amend -e
Amending the different changesets in the stack:
hg absorb
(it requires to activate the absorb extension that is distributed with mercurial)
Folding multiple commit into one (see hg stack for s1,s2,…):
hg fold -r s1::s2 --exact
Pushing Changes:
hg push --rev .
Doing Rebase:
hg rebase -d default
Original Sources:
- Markdown Version: Useful HG Commands for Tryton / Heptapod
- PDF Version : https://rentry.co/sbx5b/pdf