mirror of
https://github.com/checkpoint-restore/criu.git
synced 2026-07-17 16:47:50 +00:00
py/cli: add --version option
This patch implements the '--version' for the crit tool. $ crit --version 3.17 Signed-off-by: Radostin Stoyanov <rstoyanov@fedoraproject.org>
This commit is contained in:
parent
61d9cf6f90
commit
7a2910f897
2 changed files with 3 additions and 0 deletions
|
|
@ -364,6 +364,7 @@ def main():
|
|||
desc = 'CRiu Image Tool'
|
||||
parser = argparse.ArgumentParser(
|
||||
description=desc, formatter_class=argparse.RawTextHelpFormatter)
|
||||
parser.add_argument('--version', action='version', version=pycriu.__version__)
|
||||
|
||||
subparsers = parser.add_subparsers(
|
||||
help='Use crit CMD --help for command-specific help')
|
||||
|
|
|
|||
|
|
@ -101,6 +101,8 @@ function run_test2 {
|
|||
${CRIT} x ./ rss || exit 1
|
||||
}
|
||||
|
||||
${CRIT} --version
|
||||
|
||||
gen_imgs
|
||||
run_test1
|
||||
run_test2
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue