Rename install to process
This commit is contained in:
parent
1f62096150
commit
3c24346317
1 changed files with 6 additions and 6 deletions
12
install.py
12
install.py
|
@ -257,7 +257,7 @@ class Installer:
|
|||
|
||||
p_dest.write_text(content, append=append)
|
||||
|
||||
def install(self, programs: Optional[List[str]] = None) -> None:
|
||||
def process(self, programs: Optional[List[str]] = None) -> None:
|
||||
"""Install the programs provided.
|
||||
|
||||
If no program is provided, use the conf file to find the programs.
|
||||
|
@ -269,15 +269,15 @@ class Installer:
|
|||
programs = list(self.conf.keys())
|
||||
for program in programs:
|
||||
if ui.ask_yes_no("Do you wish to install {}?".format(program)):
|
||||
self.install_program(program)
|
||||
self.process_program(program)
|
||||
else:
|
||||
ui.info_2("Skipping {}".format(program))
|
||||
else:
|
||||
for program in programs:
|
||||
self.install_program(program)
|
||||
self.process_program(program)
|
||||
|
||||
def install_program(self, program: str) -> None:
|
||||
"""Install one program (called by self.install()).
|
||||
def process_program(self, program: str) -> None:
|
||||
"""Install one program (called by self.process()).
|
||||
|
||||
Call indivdual methods from the conf file.
|
||||
"""
|
||||
|
@ -374,7 +374,7 @@ def main() -> None:
|
|||
ui.info_1(program)
|
||||
|
||||
else:
|
||||
installer.install(programs=programs)
|
||||
installer.process(programs=programs)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
|
Loading…
Add table
Reference in a new issue