lfs: fix the inferred remote store path when using a --prefix
This wasn't appending the '.git/info/lfs' path in this case.
--- a/hgext/lfs/blobstore.py Fri Apr 13 12:39:54 2018 -0400
+++ b/hgext/lfs/blobstore.py Fri Apr 13 14:16:30 2018 -0400
@@ -561,7 +561,7 @@
if defaulturl.scheme in (b'http', b'https'):
if defaulturl.path and defaulturl.path[:-1] != b'/':
defaulturl.path += b'/'
- defaulturl.path = defaulturl.path or b'' + b'.git/info/lfs'
+ defaulturl.path = (defaulturl.path or b'') + b'.git/info/lfs'
url = util.url(bytes(defaulturl))
repo.ui.note(_('lfs: assuming remote store: %s\n') % url)
--- a/tests/test-lfs-serve-access.t Fri Apr 13 12:39:54 2018 -0400
+++ b/tests/test-lfs-serve-access.t Fri Apr 13 14:16:30 2018 -0400
@@ -73,8 +73,7 @@
> -A $TESTTMP/access.log -E $TESTTMP/errors.log
$ cat hg.pid >> $DAEMON_PIDS
- $ hg --config lfs.url=http://localhost:$HGPORT/subdir/mount/point/.git/info/lfs \
- > clone --debug http://localhost:$HGPORT/subdir/mount/point cloned2
+ $ hg clone --debug http://localhost:$HGPORT/subdir/mount/point cloned2
using http://localhost:$HGPORT/subdir/mount/point
sending capabilities command
query 1; heads
@@ -104,6 +103,7 @@
resolving manifests
branchmerge: False, force: False, partial: False
ancestor: 000000000000, local: 000000000000+, remote: 525251863cad
+ lfs: assuming remote store: http://localhost:$HGPORT/subdir/mount/point/.git/info/lfs
Status: 200
Content-Length: 371
Content-Type: application/vnd.git-lfs+json