2018-03-06 15:23:56 +03:00
|
|
|
test interaction between sparse and treemanifest (sparse file listing)
|
|
|
|
|
|
|
|
$ cat >> $HGRCPATH <<EOF
|
|
|
|
> [extensions]
|
2018-11-30 13:17:29 +03:00
|
|
|
> sparse=
|
2018-03-06 15:23:56 +03:00
|
|
|
> treemanifest=
|
|
|
|
> [treemanifest]
|
|
|
|
> treeonly = True
|
|
|
|
> [remotefilelog]
|
|
|
|
> reponame = master
|
|
|
|
> cachepath = $PWD/hgcache
|
|
|
|
> EOF
|
|
|
|
|
|
|
|
Setup the repository
|
|
|
|
|
|
|
|
$ hg init myrepo
|
|
|
|
$ cd myrepo
|
|
|
|
$ touch show
|
|
|
|
$ touch hide
|
|
|
|
$ mkdir -p subdir/foo/spam subdir/bar/ham hiddensub/foo hiddensub/bar
|
|
|
|
$ touch subdir/foo/spam/show
|
|
|
|
$ touch subdir/bar/ham/hide
|
|
|
|
$ touch hiddensub/foo/spam
|
|
|
|
$ touch hiddensub/bar/ham
|
|
|
|
$ hg add .
|
|
|
|
adding hiddensub/bar/ham
|
|
|
|
adding hiddensub/foo/spam
|
|
|
|
adding hide
|
|
|
|
adding show
|
|
|
|
adding subdir/bar/ham/hide
|
|
|
|
adding subdir/foo/spam/show
|
|
|
|
$ hg commit -m 'Init'
|
2018-10-19 16:49:05 +03:00
|
|
|
$ hg sparse include show
|
|
|
|
$ hg sparse exclude hide
|
|
|
|
$ hg sparse include subdir
|
|
|
|
$ hg sparse exclude subdir/foo
|
2018-03-06 15:23:56 +03:00
|
|
|
|
2018-10-19 16:49:05 +03:00
|
|
|
Test cwd
|
2018-03-06 15:23:56 +03:00
|
|
|
|
2018-10-19 16:49:05 +03:00
|
|
|
$ hg sparse cwd
|
2018-03-06 15:23:56 +03:00
|
|
|
- hiddensub
|
|
|
|
- hide
|
|
|
|
show
|
|
|
|
subdir
|
|
|
|
$ cd subdir
|
2018-10-19 16:49:05 +03:00
|
|
|
$ hg sparse cwd
|
2018-03-06 15:23:56 +03:00
|
|
|
bar
|
|
|
|
- foo
|
2018-10-19 16:49:05 +03:00
|
|
|
$ hg sparse include foo
|
|
|
|
$ hg sparse cwd
|
2018-03-06 15:23:56 +03:00
|
|
|
bar
|
2018-10-19 16:49:05 +03:00
|
|
|
foo
|