diff --git a/install-mpsd-software-environment.py b/install-mpsd-software-environment.py index 8ec19714bcfd7414642ee06944ebe2eeeaf56c0c..6b24b8ae3f155e52b53b54c8de9237dccbca2551 100755 --- a/install-mpsd-software-environment.py +++ b/install-mpsd-software-environment.py @@ -126,36 +126,36 @@ def main(): # Add subparsers for different actions subparsers = parser.add_subparsers(dest='action', title='actions', description='valid actions', required=True) - # Add parser for "prepare action + # Add parser for "prepare" action parser_prepare = subparsers.add_parser('prepare', help='Prepare the environment for installation on the disk') - parser_prepare.add_argument('--release', type=str, required=True, help='Release version to install') + parser_prepare.add_argument('release', type=str, help='Release version to install') # Add parser for "install" action parser_install = subparsers.add_parser('install', help='Install a software environment') - parser_install.add_argument('--release', type=str, required=True, help='Release version to install') + parser_install.add_argument('release', type=str, help='Release version to install') parser_install.add_argument('--toolchains', type=str, nargs='*', help='List of toolchains to install (use ALL to install all toolchains)', default='ALL') - parser_install.add_argument('--enable-build-cache', action='store_true', help='Enable Spack build cache. Usefull for reinstalltion but consumes time and disk space') - + parser_install.add_argument('--enable-build-cache', action='store_true', help='Enable Spack build cache. Useful for reinstallation but consumes time and disk space') + # Add parser for "reinstall" action parser_reinstall = subparsers.add_parser('reinstall', help='Reinstall a software environment') - parser_reinstall.add_argument('--release', type=str, required=True, help='Release version to install') + parser_reinstall.add_argument('release', type=str, help='Release version to install') parser_reinstall.add_argument('--toolchains', type=str, nargs='*', help='List of toolchains to install (use ALL to install all toolchains)', default='ALL') - parser_reinstall.add_argument('--enable-build-cache', action='store_true', help='Enable Spack build cache. Usefull for reinstalltion but consumes time and disk space') + parser_reinstall.add_argument('--enable-build-cache', action='store_true', help='Enable Spack build cache. Useful for reinstallation but consumes time and disk space') # Add parser for "remove" action parser_remove = subparsers.add_parser('remove', help='Remove a software environment or toolchains from an environment') - parser_remove.add_argument('--release', type=str, required=True, help='Release version to remove') + parser_remove.add_argument('release', type=str, help='Release version to remove') parser_remove.add_argument('--toolchains', type=str, nargs='*', help='Toolchains to remove (use ALL to remove all toolchains)') - parser_remove.add_argument('--enable-build-cache', action='store_true', help='Enable Spack build cache. Usefull for reinstalltion but consumes time and disk space') + parser_remove.add_argument('--enable-build-cache', action='store_true', help='Enable Spack build cache. Useful for reinstallation but consumes time and disk space') # Add parser for "start-new" action parser_start_new = subparsers.add_parser('start-new', help='Start a new software environment version') parser_start_new.add_argument('--from-release', dest='from_release', type=str, required=True, help='Release version to start from') parser_start_new.add_argument('--to-release', dest='to_release', type=str, required=True, help='Release version to create') + # Carry out the action args = parser.parse_args() - if args.action == 'remove': remove(args.release, args.toolchains,args.target_dir) elif args.action == 'start-new':