@@ -388,7 +388,7 @@ def clone(self) -> bool:
388388 return False # Already cloned
389389 logging .info ("Cloning %s into %s" , self .remote , self .directory )
390390 self .directory .mkdir (mode = 0o775 , parents = True , exist_ok = True )
391- run ([ "git" , "clone" , self .remote , self .directory ] )
391+ run (( "git" , "clone" , self .remote , self .directory ) )
392392 return True
393393
394394 def update (self ) -> None :
@@ -481,15 +481,15 @@ def version_info() -> None:
481481 """Handler for --version."""
482482 try :
483483 platex_version = head (
484- subprocess .check_output ([ "platex" , "--version" ] , text = True ),
484+ subprocess .check_output (( "platex" , "--version" ) , text = True ),
485485 lines = 3 ,
486486 )
487487 except FileNotFoundError :
488488 platex_version = "Not installed."
489489
490490 try :
491491 xelatex_version = head (
492- subprocess .check_output ([ "xelatex" , "--version" ] , text = True ),
492+ subprocess .check_output (( "xelatex" , "--version" ) , text = True ),
493493 lines = 2 ,
494494 )
495495 except FileNotFoundError :
@@ -652,7 +652,7 @@ def build(self) -> None:
652652 (self .checkout / "Doc" / "Makefile" ).write_text (text , encoding = "utf-8" )
653653
654654 self .setup_indexsidebar ()
655- run_with_logging ([
655+ run_with_logging ((
656656 "make" ,
657657 "-C" ,
658658 self .checkout / "Doc" ,
@@ -663,7 +663,7 @@ def build(self) -> None:
663663 f"SPHINXOPTS={ ' ' .join (sphinxopts )} " ,
664664 "SPHINXERRORHANDLING=" ,
665665 maketarget ,
666- ] )
666+ ) )
667667 self .log_directory .mkdir (parents = True , exist_ok = True )
668668 chgrp (self .log_directory , group = self .group , recursive = True )
669669 if self .includes_html :
@@ -678,20 +678,27 @@ def build_venv(self) -> None:
678678 So we can reuse them from builds to builds, while they contain
679679 different Sphinx versions.
680680 """
681- requirements = [ self .theme ] + self . version .requirements
681+ requirements = list ( self .version .requirements )
682682 if self .includes_html :
683683 # opengraph previews
684684 requirements .append ("matplotlib>=3" )
685685
686686 venv_path = self .build_root / f"venv-{ self .version .name } "
687687 venv .create (venv_path , symlinks = os .name != "nt" , with_pip = True )
688688 run (
689- [venv_path / "bin" / "python" , "-m" , "pip" , "install" , "--upgrade" ]
690- + ["--upgrade-strategy=eager" ]
691- + requirements ,
689+ (
690+ venv_path / "bin" / "python" ,
691+ "-m" ,
692+ "pip" ,
693+ "install" ,
694+ "--upgrade" ,
695+ "--upgrade-strategy=eager" ,
696+ self .theme ,
697+ * requirements ,
698+ ),
692699 cwd = self .checkout / "Doc" ,
693700 )
694- run ([ venv_path / "bin" / "python" , "-m" , "pip" , "freeze" , "--all" ] )
701+ run (( venv_path / "bin" / "python" , "-m" , "pip" , "freeze" , "--all" ) )
695702 self .venv = venv_path
696703
697704 def setup_indexsidebar (self ) -> None :
@@ -738,15 +745,15 @@ def copy_build_to_webroot(self, http: urllib3.PoolManager) -> None:
738745 recursive = True ,
739746 )
740747 chmod_make_readable (self .checkout / "Doc" / "build" / "html" )
741- run ([
748+ run ((
742749 "rsync" ,
743750 "-a" ,
744751 "--delete-delay" ,
745752 "--filter" ,
746753 "P archives/" ,
747754 str (self .checkout / "Doc" / "build" / "html" ) + "/" ,
748755 target ,
749- ] )
756+ ) )
750757
751758 dist_dir = self .checkout / "Doc" / "dist"
752759 if dist_dir .is_dir ():
0 commit comments