From 66d26f3fe6cb8ff802bb076fc32bfe503280d1c5 Mon Sep 17 00:00:00 2001 From: Deanna Garcia Date: Fri, 25 Jun 2021 21:07:31 +0000 Subject: [PATCH] Adding protobuf_version.bzl to get updated version in python script --- update_version.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/update_version.py b/update_version.py index 5395bd800351..9cf1dbf5ea9f 100755 --- a/update_version.py +++ b/update_version.py @@ -364,6 +364,13 @@ def UpdateRuby(): ' s.version = "%s"' % GetFullVersion(rc_suffix = '.rc.'), line)) +def UpdateBazel(): + RewriteTextFile('protobuf_version.bzl', + lambda line : re.sub( + r"^PROTOBUF_VERSION = '.*'$", + "PROTOBUF_VERSION = '%s'" % GetFullVersion(), + line)) + UpdateConfigure() UpdateCsharp() @@ -375,3 +382,4 @@ def UpdateRuby(): UpdatePhp() UpdatePython() UpdateRuby() +UpdateBazel()