##// END OF EJS Templates
share: allow trailing newline on .hg/sharedpath....
Greg Ward -
r15101:a21ccf44 default
parent child Browse files
Show More
@@ -79,7 +79,7 b' class localrepository(repo.repository):'
79
79
80 self.sharedpath = self.path
80 self.sharedpath = self.path
81 try:
81 try:
82 s = os.path.realpath(self.opener.read("sharedpath"))
82 s = os.path.realpath(self.opener.read("sharedpath").rstrip('\n'))
83 if not os.path.exists(s):
83 if not os.path.exists(s):
84 raise error.RepoError(
84 raise error.RepoError(
85 _('.hg/sharedpath points to nonexistent directory %s') % s)
85 _('.hg/sharedpath points to nonexistent directory %s') % s)
@@ -28,6 +28,15 b' Some sed versions appends newline, some '
28 $ cat .hg/sharedpath; echo
28 $ cat .hg/sharedpath; echo
29 $TESTTMP/repo1/.hg
29 $TESTTMP/repo1/.hg
30
30
31 trailing newline on .hg/sharedpath is ok
32 $ hg tip -q
33 0:d3873e73d99e
34 $ echo '' >> .hg/sharedpath
35 $ cat .hg/sharedpath
36 $TESTTMP/repo1/.hg
37 $ hg tip -q
38 0:d3873e73d99e
39
31 commit in shared clone
40 commit in shared clone
32
41
33 $ echo a >> a
42 $ echo a >> a
General Comments 0
You need to be logged in to leave comments. Login now