Commit c70643ed authored by Hao Nguyen's avatar Hao Nguyen

Update more files in update_version.py

parent d750fbf6
...@@ -86,11 +86,19 @@ def UpdateCpp(): ...@@ -86,11 +86,19 @@ def UpdateCpp():
r'^#define GOOGLE_PROTOBUF_VERSION .*$', r'^#define GOOGLE_PROTOBUF_VERSION .*$',
'#define GOOGLE_PROTOBUF_VERSION %s' % cpp_version, '#define GOOGLE_PROTOBUF_VERSION %s' % cpp_version,
line) line)
line = re.sub(
r'^#define PROTOBUF_VERSION .*$',
'#define PROTOBUF_VERSION %s' % cpp_version,
line)
if NEW_VERSION_INFO[2] == '0': if NEW_VERSION_INFO[2] == '0':
line = re.sub( line = re.sub(
r'^#define GOOGLE_PROTOBUF_MIN_LIBRARY_VERSION .*$', r'^#define GOOGLE_PROTOBUF_MIN_LIBRARY_VERSION .*$',
'#define GOOGLE_PROTOBUF_MIN_LIBRARY_VERSION %s' % cpp_version, '#define GOOGLE_PROTOBUF_MIN_LIBRARY_VERSION %s' % cpp_version,
line) line)
line = re.sub(
r'^#define PROTOBUF_MIN_HEADER_VERSION_FOR_PROTOC .*$',
'#define PROTOBUF_MIN_HEADER_VERSION_FOR_PROTOC %s' % cpp_version,
line)
line = re.sub( line = re.sub(
r'^#define GOOGLE_PROTOBUF_MIN_PROTOC_VERSION .*$', r'^#define GOOGLE_PROTOBUF_MIN_PROTOC_VERSION .*$',
'#define GOOGLE_PROTOBUF_MIN_PROTOC_VERSION %s' % cpp_version, '#define GOOGLE_PROTOBUF_MIN_PROTOC_VERSION %s' % cpp_version,
...@@ -105,6 +113,7 @@ def UpdateCpp(): ...@@ -105,6 +113,7 @@ def UpdateCpp():
line) line)
return line return line
RewriteTextFile('src/google/protobuf/stubs/common.h', RewriteCpp) RewriteTextFile('src/google/protobuf/stubs/common.h', RewriteCpp)
RewriteTextFile('src/google/protobuf/port_def.inc', RewriteCpp)
def UpdateCsharp(): def UpdateCsharp():
...@@ -125,6 +134,10 @@ def UpdateJava(): ...@@ -125,6 +134,10 @@ def UpdateJava():
lambda document : ReplaceText( lambda document : ReplaceText(
Find(document.documentElement, 'version'), NEW_VERSION)) Find(document.documentElement, 'version'), NEW_VERSION))
RewriteXml('java/bom/pom.xml',
lambda document : ReplaceText(
Find(document.documentElement, 'version'), NEW_VERSION))
RewriteXml('java/core/pom.xml', RewriteXml('java/core/pom.xml',
lambda document : ReplaceText( lambda document : ReplaceText(
Find(Find(document.documentElement, 'parent'), 'version'), Find(Find(document.documentElement, 'parent'), 'version'),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment