Changes between Version 7 and Version 8 of MercurialBranches
- Timestamp:
- Oct 8, 2010, 7:41:25 PM (14 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
MercurialBranches
v7 v8 1 1 = Mercurial Branches = 2 2 3 This page documents how to use Mercurial, rather than Subversion, to hack on Django. 3 This page documents how to use Mercurial, rather than Subversion, to hack on Django. See also DjangoBranches. 4 4 5 5 == Core developers == … … 25 25 === Tips === 26 26 27 * Use the [http://mercurial.selenic.com/wiki/BookmarksExtension bookmarks] extension for git-style local feature branches .27 * Use the [http://mercurial.selenic.com/wiki/BookmarksExtension bookmarks] extension for git-style local feature branches, or named branches for feature branches that you need other people to see. 28 28 * Alternatively, use the [http://mercurial.selenic.com/wiki/MqExtension queues] extension to manage long lived patches. 29 29 * To collapse several commits into a single commit before pushing back to svn, use the [http://mercurial.selenic.com/wiki/HisteditExtension histedit] extension … … 44 44 45 45 SHORTBRANCH="$1" 46 BRANCH="releases/$SHORTBRANCH" 46 BRANCH="releases/$SHORTBRANCH" # we only backport to release branches. 47 47 HGREV="$2" 48 48 … … 58 58 echo "Backporting Subversion revision $SVNREV" 59 59 hg update $BRANCH || exit 1; 60 # Make a commit message first in case the transplant fails. 61 hg log -r -1 --template "[$SHORTBRANCH] {desc}\n\nBackport of [$SVNREV] from trunk\n" > hg-commit-message.txt || exit 1 60 62 hg transplant $HGREV || exit 1; 61 63 # Modify the commit message 62 hg log -r -1 --template "[$SHORTBRANCH] {desc}\n\nBackport of [$SVNREV] from trunk\n" > hg-commit-message.txt || exit 163 64 hg rollback > /dev/null || exit 1 64 65 hg commit -l hg-commit-message.txt || exit 1 … … 70 71 hg_backport 1.2.X 13643 71 72 }}} 72 where 1.2.X is a directory under 'releases/' in the Subversion repo, and 13643 is a hg revision ID. The change is already committed , but not 'pushed', so you can still rollback if changes need to be made.73 where 1.2.X is a directory under 'releases/' in the Subversion repo, and 13643 is a hg revision ID. The change is already committed to the local repo, but not 'pushed', so you can still rollback if changes need to be made. 73 74