mirror of
https://gitlab.com/dslackw/slpkg.git
synced 2025-01-19 10:27:07 +01:00
Updated for coding style
This commit is contained in:
parent
62857d790d
commit
aa208b909a
3 changed files with 5 additions and 3 deletions
|
@ -21,6 +21,8 @@ class CheckUpdates(Configs):
|
|||
self.green: str = self.color['green']
|
||||
self.yellow: str = self.color['yellow']
|
||||
self.endc: str = self.color['endc']
|
||||
|
||||
# Slackbuilds.org repository settings.
|
||||
self.changelog_txt: str = self.sbo_chglog_txt
|
||||
self.local_chg_txt = Path(self.sbo_repo_path, self.changelog_txt)
|
||||
self.repo_chg_txt: str = f'{self.sbo_repo_url}{self.changelog_txt}'
|
||||
|
@ -29,6 +31,7 @@ class CheckUpdates(Configs):
|
|||
""" Checks the ChangeLogs and returns True or False. """
|
||||
local_date: int = 0
|
||||
|
||||
# Ponce repository settings.
|
||||
if self.ponce_repo:
|
||||
self.changelog_txt: str = self.ponce_chglog_txt
|
||||
self.local_chg_txt = Path(self.ponce_repo_path, self.changelog_txt)
|
||||
|
|
|
@ -324,8 +324,7 @@ class Slackbuilds(Configs):
|
|||
|
||||
def process(self, command: str) -> None:
|
||||
""" Processes execution. """
|
||||
self.output = subprocess.call(command, shell=True,
|
||||
stderr=self.stderr, stdout=self.stdout)
|
||||
self.output = subprocess.call(command, shell=True, stderr=self.stderr, stdout=self.stdout)
|
||||
if self.output != 0:
|
||||
raise SystemExit(self.output)
|
||||
|
||||
|
|
|
@ -48,7 +48,7 @@ class UpdateRepository(Configs, Utilities):
|
|||
subprocess.call(f'lftp {self.lftp_mirror_options} {self.ponce_repo_url} {self.ponce_repo_path}',
|
||||
shell=True)
|
||||
|
||||
# Remove the file before generating the new one.
|
||||
# Remove the SLACKBUILDS.TXT file before generating the new one.
|
||||
sbo_file_txt = Path(self.ponce_repo_path, self.ponce_txt)
|
||||
if sbo_file_txt.is_file():
|
||||
sbo_file_txt.unlink()
|
||||
|
|
Loading…
Reference in a new issue