mirror of
https://gitlab.com/dslackw/slpkg.git
synced 2024-12-27 09:58:10 +01:00
Updated comments
This commit is contained in:
parent
8a2d2f00d9
commit
59a3c52cfc
1 changed files with 3 additions and 3 deletions
|
@ -76,7 +76,7 @@ class Utilities(Configs):
|
|||
|
||||
@staticmethod
|
||||
def split_package(package: str) -> dict:
|
||||
""" Split the package by the name, version, arch, build and tag. """
|
||||
""" Splits the binary package name in name, version, arch, build and tag. """
|
||||
name: str = '-'.join(package.split('-')[:-3])
|
||||
version: str = ''.join(package[len(name):].split('-')[:-2])
|
||||
arch: str = ''.join(package[len(name + version) + 2:].split('-')[:-1])
|
||||
|
@ -138,7 +138,7 @@ class Utilities(Configs):
|
|||
self.errors.raise_error_message(f"No such file or directory: '{file}'", exit_status=20)
|
||||
|
||||
def read_text_file(self, file: Path) -> list:
|
||||
""" Reads the text file. """
|
||||
""" Reads the text file and returns it into a list. """
|
||||
try:
|
||||
with open(file, 'r', encoding='utf-8', errors='replace') as text_file:
|
||||
return text_file.readlines()
|
||||
|
@ -210,7 +210,7 @@ class Utilities(Configs):
|
|||
return True
|
||||
|
||||
def is_binary_repo(self, repo: str) -> bool:
|
||||
""" Checks if the repository is binary. """
|
||||
""" Returns True if the repository is binary. """
|
||||
if repo in tuple(self.repos.repositories.keys())[2:]:
|
||||
return True
|
||||
|
||||
|
|
Loading…
Reference in a new issue