##// END OF EJS Templates
internals: extract frame-based protocol docs to own document...
internals: extract frame-based protocol docs to own document wireprotocol.txt is quite long and difficult to digest. The frame-based protocol is effectively a standalone concept (and could even be used outside of Mercurial). So this commit extracts its docs to a standalone file. The first few paragraphs were rewritten as part of the extraction. Sections headers were adjusted accordingly. Existing referalls in wireprotocol.txt were updated to refer to the new doc / concept, which I've started referring to as `hgrpc`. I'm on the fence as to whether to move the HTTP and SSH transport details to the new doc as well. For now, I'm leaving them in wireprotocol.txt. Differential Revision: https://phab.mercurial-scm.org/D4443

File last commit:

r39147:46da52f4 default
r39594:b0e0db15 default
Show More
test-convert-svn-branches.t
128 lines | 3.1 KiB | text/troff | Tads3Lexer
/ tests / test-convert-svn-branches.t
Matt Mackall
tests: replace exit 80 with #require
r22046 #require svn svn-bindings
Dan Villiom Podlaski Christiansen
tests: unify test-convert-svn-*
r12370
Martin Geisler
tests: don't overwrite HGRCPATH...
r13519 $ cat >> $HGRCPATH <<EOF
Dan Villiom Podlaski Christiansen
tests: unify test-convert-svn-*
r12370 > [extensions]
Mads Kiilerich
check-code: fix check for trailing whitespace on continued lines too...
r17347 > convert =
Dan Villiom Podlaski Christiansen
tests: unify test-convert-svn-*
r12370 > EOF
$ svnadmin create svn-repo
$ svnadmin load -q svn-repo < "$TESTDIR/svn/branches.svndump"
Convert trunk and branches
$ cat > branchmap <<EOF
> old3 newbranch
Mads Kiilerich
check-code: fix check for trailing whitespace on continued lines too...
r17347 >
Patrick Mezard
convert: ignore blank lines in mapfiles (issue3286)
r16190 >
Dan Villiom Podlaski Christiansen
tests: unify test-convert-svn-*
r12370 > EOF
$ hg convert --branchmap=branchmap --datesort -r 10 svn-repo A-hg
initializing destination A-hg repository
scanning source...
sorting...
converting...
10 init projA
9 hello
8 branch trunk, remove c and dir
7 change a
6 change b
5 move and update c
4 move and update c
3 change b again
2 move to old2
1 move back to old
0 last change to a
Patrick Mezard
convert: add svnrev, svnpath and svnuuid template keywords...
r13691 Test template keywords
$ hg -R A-hg log --template '{rev} {svnuuid}{svnpath}@{svnrev}\n'
10 644ede6c-2b81-4367-9dc8-d786514f2cde/trunk@10
9 644ede6c-2b81-4367-9dc8-d786514f2cde/branches/old@9
8 644ede6c-2b81-4367-9dc8-d786514f2cde/branches/old2@8
7 644ede6c-2b81-4367-9dc8-d786514f2cde/branches/old@7
6 644ede6c-2b81-4367-9dc8-d786514f2cde/trunk@6
5 644ede6c-2b81-4367-9dc8-d786514f2cde/branches/old@6
4 644ede6c-2b81-4367-9dc8-d786514f2cde/branches/old@5
3 644ede6c-2b81-4367-9dc8-d786514f2cde/trunk@4
2 644ede6c-2b81-4367-9dc8-d786514f2cde/branches/old@3
1 644ede6c-2b81-4367-9dc8-d786514f2cde/trunk@2
0 644ede6c-2b81-4367-9dc8-d786514f2cde/trunk@1
Dan Villiom Podlaski Christiansen
tests: unify test-convert-svn-*
r12370 Convert again
$ hg convert --branchmap=branchmap --datesort svn-repo A-hg
scanning source...
sorting...
converting...
0 branch trunk@1 into old3
$ cd A-hg
Martin Geisler
tests: don't load unnecessary graphlog extension...
r20117 $ hg log -G --template 'branch={branches} {rev} {desc|firstline} files: {files}\n'
Dan Villiom Podlaski Christiansen
tests: unify test-convert-svn-*
r12370 o branch=newbranch 11 branch trunk@1 into old3 files:
|
| o branch= 10 last change to a files: a
| |
| | o branch=old 9 move back to old files:
| | |
| | o branch=old2 8 move to old2 files:
| | |
| | o branch=old 7 change b again files: b
| | |
| o | branch= 6 move and update c files: b
| | |
| | o branch=old 5 move and update c files: c
| | |
| | o branch=old 4 change b files: b
| | |
| o | branch= 3 change a files: a
| | |
| | o branch=old 2 branch trunk, remove c and dir files: c
| |/
| o branch= 1 hello files: a b c dir/e
|/
o branch= 0 init projA files:
$ hg branches
Peter Arrenbrecht
localrepo: reuse parent manifest in commitctx if no files have changed...
r14162 newbranch 11:a6d7cc050ad1
default 10:6e2b33404495
Yuya Nishihara
commit: try hard to reuse p1 manifest if nothing changed...
r39147 old 9:1b494af68c0b
old2 8:5be40b8dcbf6 (inactive)
Dan Villiom Podlaski Christiansen
tests: unify test-convert-svn-*
r12370 $ hg tags -q
tip
$ cd ..
Test hg failing to call itself
Patrick Mezard
test-convert-svn-branches.t: fix self call failure on Windows...
r17447 $ HG=foobar hg convert svn-repo B-hg 2>&1 | grep abort
Dan Villiom Podlaski Christiansen
tests: unify test-convert-svn-*
r12370 abort: Mercurial failed to run itself, check hg executable is in PATH
lstewart
convert: use branchmap to change default branch in destination (issue3469)...
r20331
Convert 'trunk' to branch other than 'default'
$ cat > branchmap <<EOF
Eugene Baranov
convert: use 'default' for specifying branch name in branchmap (issue4753)...
r25805 > default hgtrunk
lstewart
convert: use branchmap to change default branch in destination (issue3469)...
r20331 >
>
> EOF
$ hg convert --branchmap=branchmap --datesort -r 10 svn-repo C-hg
initializing destination C-hg repository
scanning source...
sorting...
converting...
10 init projA
9 hello
8 branch trunk, remove c and dir
7 change a
6 change b
5 move and update c
4 move and update c
3 change b again
2 move to old2
1 move back to old
0 last change to a
$ cd C-hg
Eugene Baranov
convert: use 'default' for specifying branch name in branchmap (issue4753)...
r25805 $ hg branches --template '{branch}\n'
hgtrunk
old
old2
lstewart
convert: use branchmap to change default branch in destination (issue3469)...
r20331 $ cd ..