Return arguments object formed by parsing the command line used to launch the program.
(spectypes)
| 349 | # ============================================================================ |
| 350 | |
| 351 | def parse_args(spectypes): |
| 352 | """ |
| 353 | Return arguments object formed by parsing the command line used to launch |
| 354 | the program. |
| 355 | """ |
| 356 | arg_parser = argparse.ArgumentParser() |
| 357 | arg_parser.add_argument( |
| 358 | "-c", "--constants", |
| 359 | help="emit constants instead of spec dict", |
| 360 | action="store_true" |
| 361 | ) |
| 362 | arg_parser.add_argument( |
| 363 | "spectype", |
| 364 | help="specifies the spec type to be generated", |
| 365 | choices=spectypes |
| 366 | ) |
| 367 | return arg_parser.parse_args() |
| 368 | |
| 369 | |
| 370 | # ============================================================================ |
no outgoing calls
no test coverage detected
searching dependent graphs…