[Python-checkins] release: Remove the "branch" operation, it is nothing more than a wrapper of "hg branch".

georg.brandl python-checkins at python.org
Sun May 8 10:09:42 CEST 2011


http://hg.python.org/release/rev/855b8c8d17d2
changeset:   56:855b8c8d17d2
user:        Georg Brandl <georg at python.org>
date:        Sun May 08 09:19:42 2011 +0200
summary:
  Remove the "branch" operation, it is nothing more than a wrapper of "hg branch".

files:
  release.py |  20 +++++++-------------
  1 files changed, 7 insertions(+), 13 deletions(-)


diff --git a/release.py b/release.py
--- a/release.py
+++ b/release.py
@@ -361,14 +361,6 @@
         return 'v' + self.text
 
 
-def branch(tag):
-    if tag.patch > 0 or tag.level != "f":
-        print('It doesn\'t look like you\'re making a final release.')
-        if input('Are you sure you want to branch?') != "y":
-            return
-    run_cmd(['hg', 'branch', tag.basic_version])
-
-
 def make_tag(tag):
     run_cmd(['hg', 'tag', tag.hgname])
 
@@ -414,17 +406,19 @@
     parser = get_arg_parser()
     options, args = parser.parse_args(argv)
     if len(args) != 2:
-        parser.print_usage()
-        sys.exit(1)
-    tag = Tag(args[1])
+        if 'RELEASE_TAG' not in os.environ:
+            parser.print_usage()
+            sys.exit(1)
+        tagname = os.environ['RELEASE_TAG']
+    else:
+        tagname = args[1]
+    tag = Tag(tagname)
     if not (options.export or options.upload):
         check_env()
     if options.bump:
         bump(tag)
     if options.tag:
         make_tag(tag)
-    if options.branch:
-        branch(tag)
     if options.export:
         export(tag)
     if options.upload:

-- 
Repository URL: http://hg.python.org/release


More information about the Python-checkins mailing list