diff --git a/stx/lib/stx/stx_build.py b/stx/lib/stx/stx_build.py index 345ac410..05d2a5b3 100644 --- a/stx/lib/stx/stx_build.py +++ b/stx/lib/stx/stx_build.py @@ -32,7 +32,7 @@ class HandleBuildTask: def buildImageCMD(self, args, prefixcmd): if args.type: - if (args.type != 'rt' and args.type != 'std'): + if args.type not in ['rt', 'std']: self.logger.error('Option -t for generaing image only should \ be [ rt|std ]') self.logger.error('Please use "stx build -h" to show the help\ diff --git a/stx/lib/stx/stx_main.py b/stx/lib/stx/stx_main.py index a172a1f2..4cc146c3 100644 --- a/stx/lib/stx/stx_main.py +++ b/stx/lib/stx/stx_main.py @@ -105,7 +105,7 @@ image.\t\teg: [ prepare|distro|image|${pkgname}]') ', action='store_true', required=False) build_subparser.add_argument('-t', '--type', help='[ rt|std ]: Select the kernel type.\ - ', nargs=1, required=False) + ', required=False) build_subparser.set_defaults(handle=self.handlebuild.handleBuild) repo_subparser = subparsers.add_parser('repomgr',