11"""Builders and path setup for installation targets."""
22
33__all__ = (
4- "makeProductPath" ,
4+ "DirectoryInstaller" ,
5+ "SConsUtilsEnvironment" ,
56 "determineVersion" ,
67 "getFingerprint" ,
8+ "makeProductPath" ,
79 "setPrefix" ,
8- "DirectoryInstaller" ,
9- "SConsUtilsEnvironment" ,
1010)
1111
1212import glob
@@ -230,7 +230,7 @@ def Declare(self, products=None):
230230 product = self ["eupsProduct" ]
231231
232232 if "EUPS_DIR" in os .environ :
233- self ["ENV" ]["PATH" ] += os .pathsep + f' { os .environ [" EUPS_DIR" ]} /bin'
233+ self ["ENV" ]["PATH" ] += os .pathsep + f" { os .environ [' EUPS_DIR' ]} /bin"
234234 self ["ENV" ]["EUPS_LOCK_PID" ] = os .environ .get ("EUPS_LOCK_PID" , "-1" )
235235 if "undeclare" in SCons .Script .COMMAND_LINE_TARGETS or self .GetOption ("clean" ):
236236 if version :
@@ -254,15 +254,15 @@ def Declare(self, products=None):
254254 )
255255
256256 if "eupsPath" in self :
257- command += f' -Z { self [" eupsPath" ] } '
257+ command += f" -Z { self [' eupsPath' ] } "
258258
259259 if version :
260260 command += f" { product } { version } "
261261
262262 current += [command + " --current" ]
263263
264264 if self .GetOption ("tag" ):
265- command += f' --tag={ self .GetOption (" tag" ) } '
265+ command += f" --tag={ self .GetOption (' tag' ) } "
266266
267267 declare += [command ]
268268
@@ -359,7 +359,7 @@ def InstallDir(self, prefix, dir, ignoreRegex=r"(~$|\.pyc$|\.os?$)", recursive=T
359359
360360
361361@memberOf (SConsEnvironment )
362- def InstallEups (env , dest , files = [] , presetup = "" ):
362+ def InstallEups (env , dest , files = () , presetup = "" ):
363363 """Install a ups directory, setting absolute versions as appropriate
364364 (unless you're installing from the trunk, in which case no versions
365365 are expanded).
@@ -370,7 +370,7 @@ def InstallEups(env, dest, files=[], presetup=""):
370370 Environment to use.
371371 dest : `str`
372372 Destination directory.
373- files : `list `, optional
373+ files : `collections.abc.Sequence `, optional
374374 List of files to install. Any build/table files present in ``./ups``
375375 are automatically added to this list.
376376 presetup : `dict`, optional
@@ -389,8 +389,10 @@ def InstallEups(env, dest, files=[], presetup=""):
389389
390390 .. code-block:: python
391391
392- env.InstallEups(os.path.join(env['prefix'], "ups"),
393- presetup={"sconsUtils" : env['version']})
392+ env.InstallEups(
393+ os.path.join(env["prefix"], "ups"),
394+ presetup={"sconsUtils": env["version"]},
395+ )
394396 """
395397 acts = []
396398 if not env .installing :
@@ -449,9 +451,9 @@ def InstallEups(env, dest, files=[], presetup=""):
449451 for i in build_obj :
450452 env .AlwaysBuild (i )
451453
452- cmd = f' eups expandbuild -i --version { env [" version" ]} '
454+ cmd = f" eups expandbuild -i --version { env [' version' ]} "
453455 if "baseversion" in env :
454- cmd += f' --repoversion { env [" baseversion" ]} '
456+ cmd += f" --repoversion { env [' baseversion' ]} "
455457 cmd += str (i )
456458 eupsTargets .extend (env .AddPostAction (build_obj , env .Action (f"{ cmd } " , cmd )))
457459
0 commit comments