Changeset 0272052c9684…
Parent a93ecb406a4b…
by
Changes to 2 files · Browse files at 0272052c9684 Showing diff from parent a93ecb406a4b Diff from another changeset...
@@ -165,7 +165,12 @@ if repo:
menus = self.menu.get_commands(repo, cwd, files)
for f in files:
- self.files.append(util.canonpath(repo.root, cwd, f))
+ cpath = util.canonpath(repo.root, cwd, f)
+ if cpath.startswith(cwd):
+ cpath = cpath[len(cwd+os.sep):]
+ self.files.append(cpath)
+ else:
+ self.files.append(f)
else:
menus = self.menu.get_norepo_commands(cwd, files)
self.cwd = cwd
|
@@ -210,7 +210,12 @@ # Convert filenames to be relative to cwd
files = []
for f in self.fnames:
- files.append(util.canonpath(self.repo.root, cwd, f))
+ cpath = util.canonpath(self.repo.root, cwd, f)
+ if cpath.startswith(cwd):
+ cpath = cpath[len(cwd+os.sep):]
+ files.append(cpath)
+ else:
+ files.append(f)
self.fnames = files
gpopts = "--command %s " % hgcmd
if filelist:
|
Loading...