You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by an...@apache.org on 2015/03/31 06:46:25 UTC
svn commit: r1670252 - in /lucene/dev/branches/branch_5x: ./ dev-tools/
dev-tools/scripts/addVersion.py
Author: anshum
Date: Tue Mar 31 04:46:24 2015
New Revision: 1670252
URL: http://svn.apache.org/r1670252
Log:
LUCENE-6380: Fix imports in addVersion.py for the release process (merge from trunk)
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/addVersion.py
Modified: lucene/dev/branches/branch_5x/dev-tools/scripts/addVersion.py
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_5x/dev-tools/scripts/addVersion.py?rev=1670252&r1=1670251&r2=1670252&view=diff
==============================================================================
--- lucene/dev/branches/branch_5x/dev-tools/scripts/addVersion.py (original)
+++ lucene/dev/branches/branch_5x/dev-tools/scripts/addVersion.py Tue Mar 31 04:46:24 2015
@@ -16,7 +16,7 @@
import os
import sys
sys.path.append(os.path.dirname(__file__))
-import scriptutil
+from scriptutil import *
import argparse
import io
@@ -36,7 +36,7 @@ def update_changes(filename, new_version
buffer.append(line)
return match is not None
- changed = scriptutil.update_file(filename, matcher, edit)
+ changed = update_file(filename, matcher, edit)
print('done' if changed else 'uptodate')
def add_constant(new_version, deprecate):
@@ -90,7 +90,7 @@ def add_constant(new_version, deprecate)
buffer.append(line)
return False
- changed = scriptutil.update_file(filename, matcher, Edit())
+ changed = update_file(filename, matcher, Edit())
print('done' if changed else 'uptodate')
version_prop_re = re.compile('version\.base=(.*)')
@@ -103,7 +103,7 @@ def update_build_version(new_version):
buffer.append('version.base=' + new_version.dot + '\n')
return True
- changed = scriptutil.update_file(filename, version_prop_re, edit)
+ changed = update_file(filename, version_prop_re, edit)
print('done' if changed else 'uptodate')
def update_latest_constant(new_version):
@@ -116,7 +116,7 @@ def update_latest_constant(new_version):
buffer.append(line.rpartition('=')[0] + ('= %s;\n' % new_version.constant))
return True
- changed = scriptutil.update_file(filename, matcher, edit)
+ changed = update_file(filename, matcher, edit)
print('done' if changed else 'uptodate')
def update_example_solrconfigs(new_version):
@@ -139,7 +139,7 @@ def update_solrconfig(filename, matcher,
buffer.append(line.replace(match.group(1), new_version.dot))
return True
- changed = scriptutil.update_file(filename, matcher, edit)
+ changed = update_file(filename, matcher, edit)
print('done' if changed else 'uptodate')
def check_lucene_version_tests():
@@ -165,7 +165,7 @@ def read_config():
parser.add_argument('-r', '--downstream-repo', help='Path to downstream checkout for given changeid')
c = parser.parse_args()
- c.branch_type = scriptutil.find_branch_type()
+ c.branch_type = find_branch_type()
c.matching_branch = c.version.is_bugfix_release() and c.branch_type == 'release' or \
c.version.is_minor_release() and c.branch_type == 'stable' or \
c.branch_type == 'major'