Skip to content

Commit

Permalink
cutarelease.py: from __future__ import print_function
Browse files Browse the repository at this point in the history
  • Loading branch information
cclauss authored Jan 25, 2025
1 parent 5c2258e commit 7594394
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions tools/cutarelease.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
Conventions:
- XXX
"""
from __future__ import print_function

__version_info__ = (1, 0, 7)
__version__ = '.'.join(map(str, __version_info__))
Expand Down Expand Up @@ -112,7 +113,7 @@ def cutarelease(project_name, version_files, dry_run=False):
"Are you sure you want cut a %s release?\n"
"This will involved commits and a push." % version,
default="no")
print "* * *"
print("* * *")
if answer != "yes":
log.info("user abort")
return
Expand All @@ -136,7 +137,7 @@ def cutarelease(project_name, version_files, dry_run=False):
"The changelog '%s' top section doesn't have the expected\n"
"'%s' marker. Has this been released already?"
% (changes_path, nyr), default="yes")
print "* * *"
print("* * *")
if answer != "no":
log.info("abort")
return
Expand Down Expand Up @@ -167,15 +168,15 @@ def cutarelease(project_name, version_files, dry_run=False):
# Optionally release.
if exists("package.json"):
answer = query_yes_no("\n* * *\nPublish to npm?", default="yes")
print "* * *"
print("* * *")
if answer == "yes":
if dry_run:
log.info("skipping npm publish (dry-run)")
else:
run('npm publish')
elif exists("setup.py"):
answer = query_yes_no("\n* * *\nPublish to pypi?", default="yes")
print "* * *"
print("* * *")
if answer == "yes":
if dry_run:
log.info("skipping pypi publish (dry-run)")
Expand Down

0 comments on commit 7594394

Please sign in to comment.