Mercurial > hgsubversion
annotate tests/fixtures/rename_branch_parent_dir.sh @ 762:c31a1f92e1c6
svnexternals: preliminary support for subrepos based externals
At this point, only pulling externals definitions into .hgsub and .hgsubstate
is supported. One difference between subrepos and svn:externals is the former
separate the source definition and target revision in two files, while
svn:externals definitions contain both. To handle this, the svn:externals
revision references is replaced with a {REV} placeholder and stored in .hgsub,
prefixed with the external base directory separated with a ':', while the
revision is extracted in .hgsubstate.
For instance, the following external:
-r3 ^/externals/proj2@2 deps/proj2
Becomes:
(.hgsub)
deps/proj2 = [hgsubversion] :-r{REV} ^/externals/proj2@2 deps/proj2
(.hgsubstate)
3 deps/proj2
author | Patrick Mezard <pmezard@gmail.com> |
---|---|
date | Thu, 25 Nov 2010 21:55:21 +0100 |
parents | d17cec76e769 |
children |
rev | line source |
---|---|
551
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
1 #!/bin/sh |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
2 mkdir temp |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
3 cd temp |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
4 svnadmin create repo |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
5 svn co file://`pwd`/repo wc |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
6 |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
7 cd wc |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
8 mkdir brances trunk tags |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
9 svn add * |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
10 svn ci -m 'btt' |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
11 |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
12 cd trunk |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
13 for a in alpha beta gamma delta ; do |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
14 echo $a > $a |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
15 svn add $a |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
16 done |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
17 svn ci -m 'Add files.' |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
18 |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
19 cd .. |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
20 svn up |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
21 svn cp trunk brances/dev_branch |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
22 svn ci -m 'branch' |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
23 |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
24 cd brances/dev_branch |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
25 svn rm delta |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
26 echo narf > alpha |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
27 echo iota > iota |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
28 svn add iota |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
29 svn ci -m 'branch changes' |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
30 |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
31 cd ../.. |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
32 svn up |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
33 svn mv brances branches |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
34 svn ci -m 'move branches to branches' |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
35 |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
36 cd .. |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
37 cd .. |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
38 |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
39 svnadmin dump temp/repo > rename_branch_parent_dir.svndump |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
40 echo |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
41 echo 'Complete.' |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
42 echo 'You probably want to clean up temp now.' |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
43 echo 'Dump in rename_branch_parent_dir.svndump' |
d17cec76e769
replay: correctly handle renaming the parent dir of a branch
Augie Fackler <durin42@gmail.com>
parents:
diff
changeset
|
44 exit 0 |