[PATCH] Make extdiff work at root directory
Andrei Vermel
avermel at mail.ru
Wed Feb 14 13:14:29 UTC 2007
Symptom:
If repo is at root dir, 'hg vdiff' fails trying to create an existing temporary dir.
# HG changeset patch
# User Andrei Vermel <avermel at mail.ru>
# Date 1171458420 -10800
# Node ID 95337102a85c84d408ecae063c0a3662cc2973c1
# Parent c4d9407fa016c5f0ae26e5ea5f58d89012694d05
Make extdiff work at root directory
diff -r c4d9407fa016 -r 95337102a85c hgext/extdiff.py
--- a/hgext/extdiff.py Wed Feb 14 16:07:00 2007 +0300
+++ b/hgext/extdiff.py Wed Feb 14 16:07:00 2007 +0300
@@ -82,6 +82,8 @@ def dodiff(ui, repo, diffcmd, diffopts,
if not using snapshot, -I/-X does not work and recursive diff
in tools like kdiff3 and meld displays too many files.'''
dirname = os.path.basename(repo.root)
+ if dirname == "":
+ dirname = "wdir"
base = os.path.join(tmproot, dirname)
os.mkdir(base)
if not ui.quiet:
-------------- next part --------------
A non-text attachment was scrubbed...
Name: extdiff_at_root
Type: application/octet-stream
Size: 786 bytes
Desc: not available
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-devel/attachments/20070214/cbdaf4d3/attachment.obj>
More information about the Mercurial-devel
mailing list