##// END OF EJS Templates
dispatch: error out on invalid -R path even if optionalrepo (issue4805) (BC)...
Yuya Nishihara -
r26142:7332bf4a default
parent child Browse files
Show More
@@ -890,6 +890,8 b' def _dispatch(req):'
890 890 except error.RequirementError:
891 891 raise
892 892 except error.RepoError:
893 if rpath and rpath[-1]: # invalid -R path
894 raise
893 895 if cmd not in commands.optionalrepo.split():
894 896 if (cmd in commands.inferrepo.split() and
895 897 args and not path): # try to infer -R from command args
@@ -1020,7 +1020,7 b" Test that auto sharing doesn't cause fai"
1020 1020 $ hg -R a id -r 0
1021 1021 acb14030fe0a
1022 1022 $ hg id -R remote -r 0
1023 abort: there is no Mercurial repository here (.hg not found)
1023 abort: repository remote not found!
1024 1024 [255]
1025 1025 $ hg --config share.pool=share -q clone -e "python \"$TESTDIR/dummyssh\"" a ssh://user@dummy/remote
1026 1026 $ hg -R remote id -r 0
@@ -589,6 +589,15 b' start without repository:'
589 589 000000000000 tip
590 590
591 591
592 don't fall back to cwd if invalid -R path is specified (issue4805):
593
594 $ cd repo
595 $ hg serve --cmdserver pipe -R ../nonexistent
596 abort: repository ../nonexistent not found!
597 [255]
598 $ cd ..
599
600
592 601 unix domain socket:
593 602
594 603 $ cd repo
@@ -43,14 +43,14 b' configure for serving'
43 43 repo not found error
44 44
45 45 $ hg clone -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy/nonexistent local
46 remote: abort: there is no Mercurial repository here (.hg not found)!
46 remote: abort: repository nonexistent not found!
47 47 abort: no suitable response from remote hg!
48 48 [255]
49 49
50 50 non-existent absolute path
51 51
52 52 $ hg clone -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy//`pwd`/nonexistent local
53 remote: abort: there is no Mercurial repository here (.hg not found)!
53 remote: abort: repository /$TESTTMP/nonexistent not found!
54 54 abort: no suitable response from remote hg!
55 55 [255]
56 56
@@ -128,7 +128,7 b' pull from wrong ssh URL'
128 128
129 129 $ hg pull -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy/doesnotexist
130 130 pulling from ssh://user@dummy/doesnotexist
131 remote: abort: there is no Mercurial repository here (.hg not found)!
131 remote: abort: repository doesnotexist not found!
132 132 abort: no suitable response from remote hg!
133 133 [255]
134 134
@@ -34,14 +34,14 b' configure for serving'
34 34 repo not found error
35 35
36 36 $ hg clone -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy/nonexistent local
37 remote: abort: there is no Mercurial repository here (.hg not found)!
37 remote: abort: repository nonexistent not found!
38 38 abort: no suitable response from remote hg!
39 39 [255]
40 40
41 41 non-existent absolute path
42 42
43 43 $ hg clone -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy/`pwd`/nonexistent local
44 remote: abort: there is no Mercurial repository here (.hg not found)!
44 remote: abort: repository $TESTTMP/nonexistent not found!
45 45 abort: no suitable response from remote hg!
46 46 [255]
47 47
@@ -119,7 +119,7 b' pull from wrong ssh URL'
119 119
120 120 $ hg pull -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy/doesnotexist
121 121 pulling from ssh://user@dummy/doesnotexist
122 remote: abort: there is no Mercurial repository here (.hg not found)!
122 remote: abort: repository doesnotexist not found!
123 123 abort: no suitable response from remote hg!
124 124 [255]
125 125
General Comments 0
You need to be logged in to leave comments. Login now