File tree 1 file changed +7
-3
lines changed
1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change 8
8
deps_dir .mkdir ()
9
9
10
10
if not (deps_dir / "venvstarter.py" ).exists ():
11
+ if "PIP_REQUIRE_VIRTUALENV" in os .environ :
12
+ del os .environ ["PIP_REQUIRE_VIRTUALENV" ]
11
13
os .system (f"{ sys .executable } -m pip install venvstarter -t { deps_dir } " )
12
14
15
+ sys .path .append (str (deps_dir ))
13
16
venvstarter_module = runpy .run_path (str (deps_dir / "venvstarter.py" ))
17
+ sys .path .pop ()
14
18
15
- wanted_version = "0.11.0 "
19
+ wanted_version = "0.12.2 "
16
20
17
21
upgrade = False
18
22
VERSION = venvstarter_module .get ("VERSION" )
19
23
if VERSION is None :
20
24
upgrade = True
21
25
else :
22
26
Version = venvstarter_module ["Version" ]
23
- if Version (wanted_version ) < Version (VERSION ):
27
+ if Version (VERSION ) != Version (wanted_version ):
24
28
upgrade = True
25
29
26
30
if upgrade :
27
- os .system (f"{ sys .executable } -m pip install 'venvstarter> ={ wanted_version } ' -t { deps_dir } " )
31
+ os .system (f"{ sys .executable } -m pip install -U 'venvstarter= ={ wanted_version } ' -t { deps_dir } " )
28
32
29
33
manager = runpy .run_path (str (deps_dir / "venvstarter.py" ))["manager" ]
You can’t perform that action at this time.
0 commit comments