You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by rj...@apache.org on 2014/11/15 22:27:57 UTC
svn commit: r1639926 - in /lucene/dev/branches/branch_5x: ./ dev-tools/
dev-tools/scripts/createPatch.py
Author: rjernst
Date: Sat Nov 15 21:27:56 2014
New Revision: 1639926
URL: http://svn.apache.org/r1639926
Log:
One more fix for patch tool to make paths relative to checkouts work (merged 1639925)
Modified:
lucene/dev/branches/branch_5x/ (props changed)
lucene/dev/branches/branch_5x/dev-tools/ (props changed)
lucene/dev/branches/branch_5x/dev-tools/scripts/createPatch.py
Modified: lucene/dev/branches/branch_5x/dev-tools/scripts/createPatch.py
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_5x/dev-tools/scripts/createPatch.py?rev=1639926&r1=1639925&r2=1639926&view=diff
==============================================================================
--- lucene/dev/branches/branch_5x/dev-tools/scripts/createPatch.py (original)
+++ lucene/dev/branches/branch_5x/dev-tools/scripts/createPatch.py Sat Nov 15 21:27:56 2014
@@ -102,8 +102,8 @@ def find_root(path):
relative = []
while not os.path.exists(os.path.join(path, 'lucene', 'CHANGES.txt')):
path, base = os.path.split(path)
- relative.prepend(base)
- return path, '' if not relative else os.path.join(relative)
+ relative.insert(0, base)
+ return path, '' if not relative else os.path.normpath(os.path.join(*relative))
def parse_config():
parser = ArgumentParser(description=__doc__, formatter_class=RawTextHelpFormatter)
@@ -125,7 +125,7 @@ def parse_config():
parser.error('\'to\' path %s is not relative to a lucene/solr checkout' % c.to_dir)
if from_relative != to_relative:
parser.error('\'from\' and \'to\' path are not equivalent relative paths within their'
- ' checkouts: %s != %s' % (from_relative, to_relative))
+ ' checkouts: %r != %r' % (from_relative, to_relative))
return c
def main():