2010-08-12 10:18:44 +04:00
|
|
|
$ hg init a
|
|
|
|
$ hg clone a b
|
|
|
|
updating to branch default
|
|
|
|
0 files updated, 0 files merged, 0 files removed, 0 files unresolved
|
|
|
|
$ cd a
|
|
|
|
$ echo '[paths]' >> .hg/hgrc
|
|
|
|
$ echo 'dupe = ../b' >> .hg/hgrc
|
2010-10-09 21:28:16 +04:00
|
|
|
$ echo 'expand = $SOMETHING/bar' >> .hg/hgrc
|
2010-08-12 10:18:44 +04:00
|
|
|
$ hg in dupe
|
2010-10-09 07:36:10 +04:00
|
|
|
comparing with $TESTTMP/b
|
2010-08-12 10:18:44 +04:00
|
|
|
no changes found
|
2010-09-17 02:51:32 +04:00
|
|
|
[1]
|
2010-08-12 10:18:44 +04:00
|
|
|
$ cd ..
|
|
|
|
$ hg -R a in dupe
|
2010-10-09 07:36:10 +04:00
|
|
|
comparing with $TESTTMP/b
|
2010-08-12 10:18:44 +04:00
|
|
|
no changes found
|
2010-09-17 02:51:32 +04:00
|
|
|
[1]
|
2010-10-09 21:28:16 +04:00
|
|
|
$ cd a
|
|
|
|
$ hg paths
|
|
|
|
dupe = $TESTTMP/b
|
|
|
|
expand = $TESTTMP/a/$SOMETHING/bar
|
|
|
|
$ SOMETHING=foo hg paths
|
|
|
|
dupe = $TESTTMP/b
|
|
|
|
expand = $TESTTMP/a/foo/bar
|
|
|
|
$ SOMETHING=/foo hg paths
|
|
|
|
dupe = $TESTTMP/b
|
|
|
|
expand = /foo/bar
|
2011-05-16 13:41:48 +04:00
|
|
|
$ hg paths -q
|
|
|
|
dupe
|
|
|
|
expand
|
|
|
|
$ hg paths dupe
|
|
|
|
$TESTTMP/b
|
|
|
|
$ hg paths -q dupe
|
|
|
|
$ hg paths unknown
|
|
|
|
not found!
|
|
|
|
[1]
|
|
|
|
$ hg paths -q unknown
|
|
|
|
[1]
|
2011-03-29 21:20:28 +04:00
|
|
|
$ cd ..
|
|
|
|
|
|
|
|
'file:' disables [paths] entries for clone destination
|
|
|
|
|
|
|
|
$ cat >> $HGRCPATH <<EOF
|
|
|
|
> [paths]
|
|
|
|
> gpath1 = http://hg.example.com
|
|
|
|
> EOF
|
|
|
|
|
|
|
|
$ hg clone a gpath1
|
|
|
|
abort: cannot create new http repository
|
|
|
|
[255]
|
|
|
|
|
|
|
|
$ hg clone a file:gpath1
|
|
|
|
updating to branch default
|
|
|
|
0 files updated, 0 files merged, 0 files removed, 0 files unresolved
|
|
|
|
$ cd gpath1
|
|
|
|
$ hg -q id
|
|
|
|
000000000000
|
|
|
|
|