def execute(argv): project_loader = ProjectLoader() cmakelists_builder = CMakeListsBuilder() project_builder = ProjectCommands() service = CompilationService(project_loader, cmakelists_builder, project_builder) result = clean_project(service) return result
def execute(argv): create_parser = argparse.ArgumentParser(prog='cpm build', description='cpm build', add_help=False) create_parser.add_argument('target', nargs='?', default='default') args = create_parser.parse_args(argv) project_loader = ProjectLoader() cmakelists_builder = CMakeListsBuilder() project_commands = ProjectCommands() service = CompilationService(project_loader, cmakelists_builder, project_commands) result = build_project(service, args.target) return result
def execute(argv): add_target_parser = argparse.ArgumentParser( prog='cpm test', description='cpm, modern C/C++ system', add_help=False) add_target_parser.add_argument('files_or_dirs', nargs=argparse.REMAINDER) args = add_target_parser.parse_args(argv) project_loader = ProjectLoader() cmakelists_builder = CMakeListsBuilder() project_commands = ProjectCommands() service = TestService(project_loader, cmakelists_builder, project_commands) result = run_tests(service, args.files_or_dirs) return result