Revision 680fed02
b/devflow/versioning.py | ||
---|---|---|
412 | 412 |
sys.stdout.write("usage: %s version\n" % sys.argv[0]) |
413 | 413 |
|
414 | 414 |
|
415 |
def bump_version(new_version): |
|
416 |
"""Set new base version to base version file and commit""" |
|
417 |
v = utils.get_vcs_info() |
|
418 |
mode = utils.get_build_mode() |
|
419 |
|
|
420 |
# Check that new base version is valid |
|
421 |
python_version(new_version, v, mode) |
|
422 |
|
|
415 |
def _bump_version(new_version, v): |
|
423 | 416 |
repo = utils.get_repository() |
424 | 417 |
toplevel = repo.working_dir |
425 |
|
|
426 | 418 |
old_version = get_base_version(v) |
427 | 419 |
sys.stdout.write("Current base version is '%s'\n" % old_version) |
428 | 420 |
|
... | ... | |
445 | 437 |
sys.stdout.write("Update version file and commited\n") |
446 | 438 |
|
447 | 439 |
|
440 |
def bump_version(new_version): |
|
441 |
"""Set new base version to base version file and commit""" |
|
442 |
v = utils.get_vcs_info() |
|
443 |
|
|
444 |
# Check that new base version is valid |
|
445 |
validate_version(new_version, v) |
|
446 |
_bump_version(new_version, v) |
|
447 |
|
|
448 |
|
|
449 |
|
|
448 | 450 |
def main(): |
449 | 451 |
v = utils.get_vcs_info() |
450 | 452 |
b = get_base_version(v) |
Also available in: Unified diff