Mercurial > repos > shellac > guppy_basecaller
comparison env/lib/python3.7/site-packages/ephemeris/common_parser.py @ 0:26e78fe6e8c4 draft
"planemo upload commit c699937486c35866861690329de38ec1a5d9f783"
author | shellac |
---|---|
date | Sat, 02 May 2020 07:14:21 -0400 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:26e78fe6e8c4 |
---|---|
1 #!/usr/bin/env python | |
2 | |
3 import argparse | |
4 | |
5 | |
6 def get_common_args(login_required=True, log_file=False): | |
7 | |
8 parser = argparse.ArgumentParser(add_help=False) | |
9 general_group = parser.add_argument_group('General options') | |
10 general_group.add_argument("-v", "--verbose", help="Increase output verbosity.", action="store_true") | |
11 if log_file: | |
12 general_group.add_argument("--log_file", | |
13 dest="log_file", | |
14 help="Where the log file should be stored. " | |
15 "Default is a file in your system's temp folder", | |
16 default=None) | |
17 | |
18 con_group = parser.add_argument_group('Galaxy connection') | |
19 con_group.add_argument("-g", "--galaxy", | |
20 help="Target Galaxy instance URL/IP address", | |
21 default="http://localhost:8080") | |
22 | |
23 if login_required: | |
24 con_group.add_argument("-u", "--user", | |
25 help="Galaxy user email address") | |
26 con_group.add_argument("-p", "--password", | |
27 help="Password for the Galaxy user") | |
28 con_group.add_argument("-a", "--api_key", | |
29 dest="api_key", | |
30 help="Galaxy admin user API key (required if not defined in the tools list file)") | |
31 | |
32 return parser |