13
13
14
14
import click
15
15
16
- from python_inspector import pyinspector_settings as settings
16
+ from python_inspector import settings
17
17
from python_inspector import utils_pypi
18
18
from python_inspector .cli_utils import FileOptionType
19
19
from python_inspector .utils import write_output_in_file
20
20
21
21
TRACE = False
22
22
23
- __version__ = "0.13 .0"
23
+ __version__ = "0.14 .0"
24
24
25
25
DEFAULT_PYTHON_VERSION = settings .DEFAULT_PYTHON_VERSION
26
+ PYPI_SIMPLE_URL = settings .PYPI_SIMPLE_URL
26
27
27
28
28
29
def print_version (ctx , param , value ):
@@ -71,7 +72,6 @@ def print_version(ctx, param, value):
71
72
"python_version" ,
72
73
type = click .Choice (utils_pypi .valid_python_versions ),
73
74
metavar = "PYVER" ,
74
- default = settings .DEFAULT_PYTHON_VERSION ,
75
75
show_default = True ,
76
76
required = True ,
77
77
help = "Python version to use for dependency resolution. One of "
@@ -83,19 +83,18 @@ def print_version(ctx, param, value):
83
83
"operating_system" ,
84
84
type = click .Choice (utils_pypi .PLATFORMS_BY_OS ),
85
85
metavar = "OS" ,
86
- default = settings .DEFAULT_OS ,
87
86
show_default = True ,
88
87
required = True ,
89
88
help = "OS to use for dependency resolution. One of " + ", " .join (utils_pypi .PLATFORMS_BY_OS ),
90
89
)
91
90
@click .option (
92
91
"--index-url" ,
93
92
"index_urls" ,
94
- envvar = "PYINSP_INDEX_URL" ,
95
93
type = str ,
96
94
metavar = "INDEX" ,
97
95
show_default = True ,
98
- default = tuple (settings .INDEX_URL ),
96
+ # since multiple is True, this is a sequence
97
+ default = [settings .PYPI_SIMPLE_URL ],
99
98
multiple = True ,
100
99
help = "PyPI simple index URL(s) to use in order of preference. "
101
100
"This option can be used multiple times." ,
@@ -123,7 +122,6 @@ def print_version(ctx, param, value):
123
122
"--netrc" ,
124
123
"netrc_file" ,
125
124
type = click .Path (exists = True , readable = True , path_type = str , dir_okay = False ),
126
- envvar = "PYINSP_NETRC_FILE" ,
127
125
metavar = "NETRC-FILE" ,
128
126
hidden = True ,
129
127
required = False ,
@@ -165,7 +163,6 @@ def print_version(ctx, param, value):
165
163
)
166
164
@click .option (
167
165
"--verbose" ,
168
- envvar = "PYINSP_VERBOSE" ,
169
166
is_flag = True ,
170
167
help = "Enable verbose debug output." ,
171
168
)
0 commit comments