def get_config(): """Parse command line arguments, extracting the config file name, returning the union of config file and command line arguments :return: dict of config file settings and command line arguments """ config = GitTool.get_project_config() # TODO update description parser = argparse.ArgumentParser( formatter_class=argparse.RawDescriptionHelpFormatter, description='''\ Update version of docker ready to commit. ''', epilog='''\ ''') parser.add_argument('--version', required=True, help="Version of ERPLibre.") parser.add_argument('--base', required=True, help="Docker base name.") parser.add_argument('--prod', required=True, help="Docker prod name.") parser.add_argument('--docker_compose_file', default="./docker-compose.yml", help="Docker compose file to update.") parser.add_argument('--docker_prod', default="./docker/Dockerfile.prod.pkg", help="Docker prod file to update.") args = parser.parse_args() args.base_version = f"{args.base}:{args.version}" args.prod_version = f"{args.prod}:{args.version}" return args
def get_config(): """Parse command line arguments, extracting the config file name, returning the union of config file and command line arguments :return: dict of config file settings and command line arguments """ config = GitTool.get_project_config() # TODO update description parser = argparse.ArgumentParser( formatter_class=argparse.RawDescriptionHelpFormatter, description="""\ Transform a xml file in code writer format xml file. """, epilog="""\ """, ) parser.add_argument( "-f", "--file", dest="file", required=True, help="Path of file to transform to code_writer.", ) parser.add_argument( "-o", "--output", dest="output", help="The output file." ) args = parser.parse_args() return args
def get_config(): """Parse command line arguments, extracting the config file name, returning the union of config file and command line arguments :return: dict of config file settings and command line arguments """ config = GitTool.get_project_config() # TODO update description parser = argparse.ArgumentParser( formatter_class=argparse.RawDescriptionHelpFormatter, description='''\ ''', epilog='''\ ''' ) parser.add_argument('-d', '--dir', dest="dir", default="./", help="Path of repo to change remote, including submodule.") parser.add_argument('--organization', dest="organization", default="ERPLibre", help="Choose organization to fork and change all repo.") parser.add_argument("--skip_fork", action="store_true", help="Ignore fork to generate only manifest.") parser.add_argument('-f', "--force", action="store_true", help="Force rewrite remote.") parser.add_argument("--fast", action="store_true", help="Ignore if repo already exist.") parser.add_argument('--github_token', dest="github_token", default=config.get(CST_EL_GITHUB_TOKEN), help="GitHub token generated by user") args = parser.parse_args() return args
def get_config(): """Parse command line arguments, extracting the config file name, returning the union of config file and command line arguments :return: dict of config file settings and command line arguments """ config = GitTool.get_project_config() # TODO update description parser = argparse.ArgumentParser( formatter_class=argparse.RawDescriptionHelpFormatter, description='''\ Update config.conf file with group specified in manifest file. ''', epilog='''\ ''' ) parser.add_argument('--group', default="", help="Prod by default, use 'dev' for manifest/default.dev.xml") args = parser.parse_args() return args
def get_config(): """Parse command line arguments, extracting the config file name, returning the union of config file and command line arguments :return: dict of config file settings and command line arguments """ config = GitTool.get_project_config() # TODO update description parser = argparse.ArgumentParser( formatter_class=argparse.RawDescriptionHelpFormatter, description="""\ """, epilog="""\ """, ) parser.add_argument( "-d", "--dir", dest="dir", default="./", help="Path of repo to change remote, including submodule.", ) parser.add_argument( "--organization", dest="organization", default="ERPLibre", help="Choose organization to fork and change all repo.", ) parser.add_argument( "--github_token", dest="github_token", default=config.get(CST_EL_GITHUB_TOKEN), help="GitHub token generated by user", ) args = parser.parse_args() return args