--- a/hgext/extdiff.py Wed Dec 31 18:00:35 2008 -0600
+++ b/hgext/extdiff.py Fri Jan 02 22:53:33 2009 +0100
@@ -80,9 +80,7 @@
'''snapshot files from working directory.
if not using snapshot, -I/-X does not work and recursive diff
in tools like kdiff3 and meld displays too many files.'''
- repo_root = repo.root
-
- dirname = os.path.basename(repo_root)
+ dirname = os.path.basename(repo.root)
if dirname == "":
dirname = "root"
base = os.path.join(tmproot, dirname)
@@ -105,8 +103,7 @@
fp.write(chunk)
fp.close()
- fns_and_mtime.append((dest, os.path.join(repo_root, fn),
- os.path.getmtime(dest)))
+ fns_and_mtime.append((dest, repo.wjoin(fn), os.path.getmtime(dest)))
return dirname, fns_and_mtime
--- a/hgext/purge.py Wed Dec 31 18:00:35 2008 -0600
+++ b/hgext/purge.py Fri Jan 02 22:53:33 2009 +0100
@@ -64,7 +64,7 @@
def remove(remove_func, name):
if act:
try:
- remove_func(os.path.join(repo.root, name))
+ remove_func(repo.wjoin(name))
except OSError:
m = _('%s cannot be removed') % name
if opts['abort_on_err']:
--- a/mercurial/commands.py Wed Dec 31 18:00:35 2008 -0600
+++ b/mercurial/commands.py Fri Jan 02 22:53:33 2009 +0100
@@ -1797,7 +1797,7 @@
if not rev and abs not in repo.dirstate:
continue
if opts.get('fullpath'):
- ui.write(os.path.join(repo.root, abs), end)
+ ui.write(repo.wjoin(abs), end)
else:
ui.write(((pats and m.rel(abs)) or abs), end)
ret = 0
--- a/mercurial/patch.py Wed Dec 31 18:00:35 2008 -0600
+++ b/mercurial/patch.py Fri Jan 02 22:53:33 2009 +0100
@@ -1057,7 +1057,7 @@
gp = patches[f]
if gp and gp.mode:
islink, isexec = gp.mode
- dst = os.path.join(repo.root, gp.path)
+ dst = repo.wjoin(gp.path)
# patch won't create empty files
if gp.op == 'ADD' and not os.path.exists(dst):
flags = (isexec and 'x' or '') + (islink and 'l' or '')