Updated for new repositories.toml file

This commit is contained in:
Dimitris Zlatanidis 2024-04-12 19:14:57 +03:00
parent 7f34999f83
commit ed45b11d10
6 changed files with 332 additions and 454 deletions

View file

@ -1,6 +1,6 @@
## slpkg - ChangeLog
### 5.0.5 - 08/04/2024
### 5.0.5 - 12/04/2024
- Added:
* Added maximum parallel for downloading in the config file
* Added --pkg-version option in search command
@ -12,7 +12,7 @@
- Updated:
* Updated to exclude packages from slack_extra repository (Thanks to Marav)
* Updated salixos mirrors
* Updated repositories.toml file
* Updated the repositories.toml config file
- Fixed:
* Fixed BrokenPipeError: [Errno 32] Broken pipe

View file

@ -1,18 +1,9 @@
# This is the general repositories configuration file of slpkg:
# /etc/slpkg/repositories.toml
# Updated: 11/04/2024, Version: 5.0.5
# Updated: 12/04/2024, Version: 5.0.5
# Set 'true' or 'false' to enable or disable the repository you want.
# DO NOT CHANGE THE PATTERN OF THE MIRRORS, CHANGE ONLY WHAT YOU WANT.
# Example for alien repository and Slackware -current users should be:
# ["https://slackware.nl/people/alien/sbrepos/", "current/", "x86_64/"]
# and NOT:
# ["https://slackware.nl/people/alien/sbrepos/current/x86_64/"]
# SalixOs users, they should change the slack's repositories mirrors.
# ["https://repo.greeklug.gr/data/pub/linux/salix/x86_64/slackware-15.0/"]
# Notes: Before using a repository, make sure you have read about it.
# Some repositories are for -current only. Change the mirror
# if it is necessary. The mirror or every part of the mirror
@ -26,76 +17,115 @@ REPO = "sbo"
[SBO]
ENABLE = true
MIRROR = ["https://slackbuilds.org/slackbuilds/15.0/"]
MIRROR = "https://slackbuilds.org/slackbuilds/"
VERSION = "15.0"
[PONCE]
ENABLE = false
MIRROR = ["https://cgit.ponce.cc/slackbuilds/plain/"]
MIRROR = "https://cgit.ponce.cc/slackbuilds/plain/"
VERSION = "current"
[SLACK]
ENABLE = false
MIRROR = ["https://slackware.uk/slackware/slackware64-15.0/"]
MIRROR = "https://slackware.uk/slackware/"
VERSION = "15.0"
ARCH = "x86_64"
[SLACK_EXTRA]
ENABLE = false
MIRROR = ["https://slackware.uk/slackware/slackware64-15.0/", "extra/"]
MIRROR = "https://slackware.uk/slackware/"
VERSION = "15.0"
ARCH = "x86_64"
BRANCH = "extra"
[SLACK_PATCHES]
ENABLE = false
MIRROR = ["https://slackware.uk/slackware/slackware64-15.0/", "patches/"]
MIRROR = "https://slackware.uk/slackware/"
VERSION = "15.0"
ARCH = "x86_64"
BRANCH = "pacthes"
[ALIEN]
ENABLE = false
MIRROR = ["https://slackware.nl/people/alien/sbrepos/", "15.0/", "x86_64/"]
MIRROR = "https://slackware.nl/people/alien/sbrepos/"
VERSION = "15.0"
ARCH = "x86_64"
[MULTILIB]
ENABLE = false
MIRROR = ["https://slackware.nl/people/alien/multilib/", "15.0/"]
MIRROR = "https://slackware.nl/people/alien/multilib/"
VERSION = "15.0"
[RESTRICTED]
ENABLE = false
MIRROR = ["https://slackware.nl/people/alien/restricted_sbrepos/", "15.0/", "x86_64/"]
MIRROR = "https://slackware.nl/people/alien/restricted_sbrepos/"
VERSION = "15.0"
ARCH = "x86_64"
[GNOME]
ENABLE = false
MIRROR = ["https://reddoglinux.ddns.net/linux/gnome/41.x/x86_64/"]
MIRROR = "https://reddoglinux.ddns.net/linux/gnome/"
VERSION = "41.x"
ARCH = "x86_64"
[MSB]
ENABLE = false
MIRROR = ["https://slackware.uk/msb/", "15.0/", "1.28/", "x86_64/"]
MIRROR = "https://slackware.uk/msb/"
VERSION = "15.0"
ARCH = "x86_64"
BRANCH = "1.28"
[CSB]
ENABLE = false
MIRROR = ["https://slackware.uk/csb/", "15.0/", "x86_64/"]
MIRROR = "https://slackware.uk/csb/"
VERSION = "15.0"
ARCH = "x86_64"
[CONRAID]
ENABLE = false
MIRROR = ["https://slackers.it/repository/slackware64-current/"]
MIRROR = "https://slackers.it/repository/"
VERSION = "current"
ARCH = "x86_64"
[SLACKDCE]
ENABLE = false
MIRROR = ["https://slackware.uk/slackdce/15.0/x86_64/"]
MIRROR = "https://slackware.uk/slackdce/"
VERSION = "15.0"
ARCH = "x86_64"
[SLACKONLY]
ENABLE = false
MIRROR = ["https://packages.slackonly.com/pub/packages/15.0-x86_64/"]
MIRROR = "https://packages.slackonly.com/pub/packages/"
VERSION = "15.0"
ARCH = "x86_64"
[SALIX]
ENABLE = false
MIRROR = ["https://repo.greeklug.gr/data/pub/linux/salix/x86_64/15.0/"]
MIRROR = "https://repo.greeklug.gr/data/pub/linux/salix/"
VERSION = "15.0"
ARCH = "x86_64"
[SALIX_EXTRA]
ENABLE = false
MIRROR = ["https://repo.greeklug.gr/data/pub/linux/salix/x86_64/extra-15.0/"]
MIRROR = "https://repo.greeklug.gr/data/pub/linux/salix/"
VERSION = "15.0"
ARCH = "x86_64"
BRANCH = "extra"
[SLACKEL]
ENABLE = false
MIRROR = ["http://www.slackel.gr/repo/x86_64/current/"]
MIRROR = "http://www.slackel.gr/repo/"
VERSION = "current"
ARCH = "x86_64"
[SLINT]
ENABLE = false
MIRROR = ["https://slackware.uk/slint/x86_64/slint-15.0/"]
MIRROR = "https://slackware.uk/slint/"
VERSION = "15.0"
ARCH = "x86_64"
[PPRKUT]
ENABLE = false
MIRROR = ["https://repo.liwjatan.org/pprkut/15.0/x86_64/"]
MIRROR = "https://repo.liwjatan.org/pprkut/"
VERSION = "15.0"
ARCH = "x86_64"

View file

@ -59,9 +59,12 @@ class CheckUpdates(Configs):
self.repositories(repo)
def repositories(self, repo: str) -> None:
local_chg_txt: Path = Path(self.repos.repositories[repo]['path'], self.repos.repositories[repo]['changelog_txt'])
repo_chg_txt: str = f"{self.repos.repositories[repo]['mirror'][0]}{self.repos.repositories[repo]['changelog_txt']}"
repo_data_file: Path = Path(self.repos.repositories[repo]['path'], self.repos.data_json)
local_chg_txt: Path = Path(self.repos.repositories[repo]['path'],
self.repos.repositories[repo]['changelog_txt'])
repo_chg_txt: str = (f"{self.repos.repositories[repo]['mirror_changelog']}"
f"{self.repos.repositories[repo]['changelog_txt']}")
repo_data_file: Path = Path(self.repos.repositories[repo]['path'],
self.repos.data_json)
if not repo_data_file.is_file():
self.compare[repo] = True

View file

@ -213,7 +213,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.slack_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = self.repos.slack_repo_mirror[0]
mirror: str = self.repos.slack_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -308,7 +308,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.slack_extra_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = self.repos.slack_extra_repo_mirror[0]
mirror: str = self.repos.slack_extra_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -403,7 +403,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.slack_patches_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = self.repos.slack_patches_repo_mirror[0]
mirror: str = self.repos.slack_patches_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -498,7 +498,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.alien_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = ''.join(self.repos.alien_repo_mirror)
mirror: str = self.repos.alien_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -598,7 +598,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.multilib_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = ''.join(self.repos.multilib_repo_mirror)
mirror: str = self.repos.multilib_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -693,7 +693,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.restricted_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = ''.join(self.repos.restricted_repo_mirror)
mirror: str = self.repos.restricted_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -788,7 +788,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.gnome_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = self.repos.gnome_repo_mirror[0]
mirror: str = self.repos.gnome_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -884,7 +884,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.msb_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = ''.join(self.repos.msb_repo_mirror)
mirror: str = self.repos.msb_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -979,7 +979,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.csb_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = ''.join(self.repos.csb_repo_mirror)
mirror: str = self.repos.csb_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -1074,7 +1074,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.conraid_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = self.repos.conraid_repo_mirror[0]
mirror: str = self.repos.conraid_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -1170,7 +1170,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.slackdce_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = self.repos.slackdce_repo_mirror[0]
mirror: str = self.repos.slackdce_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -1270,7 +1270,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.slackonly_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = self.repos.slackonly_repo_mirror[0]
mirror: str = self.repos.slackonly_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -1370,7 +1370,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.salix_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = self.repos.salix_repo_mirror[0]
mirror: str = self.repos.salix_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -1478,7 +1478,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.salix_extra_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = self.repos.salix_extra_repo_mirror[0]
mirror: str = self.repos.salix_extra_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -1586,7 +1586,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.slackel_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = self.repos.slackel_repo_mirror[0]
mirror: str = self.repos.slackel_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -1694,7 +1694,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.slint_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = self.repos.slint_repo_mirror[0]
mirror: str = self.repos.slint_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)
@ -1802,7 +1802,7 @@ class InstallData(Configs):
print(f"\nUpdating the database for '{self.cyan}{self.repos.pprkut_repo_name}{self.endc}'... ",
end='', flush=True)
mirror: str = ''.join(self.repos.pprkut_repo_mirror)
mirror: str = self.repos.pprkut_repo_mirror_packages
self._import_GPG_KEY(mirror=mirror)

View file

@ -31,7 +31,8 @@ class Repositories:
sbo_repo: bool = True
sbo_repo_name: str = 'sbo'
sbo_repo_path: Path = Path(repositories_path, sbo_repo_name)
sbo_repo_mirror = ['https://slackbuilds.org/slackbuilds/15.0/']
sbo_repo_mirror_packages: str = ''
sbo_repo_mirror_changelog: str = ''
sbo_repo_slackbuilds: str = 'SLACKBUILDS.TXT'
sbo_repo_changelog: str = 'ChangeLog.txt'
sbo_repo_tag: str = '_SBo'
@ -40,7 +41,8 @@ class Repositories:
ponce_repo: bool = False
ponce_repo_name: str = 'ponce'
ponce_repo_path: Path = Path(repositories_path, ponce_repo_name)
ponce_repo_mirror = ['https://cgit.ponce.cc/slackbuilds/plain/']
ponce_repo_mirror_packages: str = ''
ponce_repo_mirror_changelog: str = ''
ponce_repo_slackbuilds: str = 'SLACKBUILDS.TXT'
ponce_repo_changelog: str = 'ChangeLog.txt'
ponce_repo_tag: str = '_SBo'
@ -49,7 +51,8 @@ class Repositories:
slack_repo: bool = False
slack_repo_name: str = 'slack'
slack_repo_path: Path = Path(repositories_path, slack_repo_name)
slack_repo_mirror = ['https://slackware.uk/slackware/slackware64-15.0/']
slack_repo_mirror_packages: str = ''
slack_repo_mirror_changelog: str = ''
slack_repo_packages: str = 'PACKAGES.TXT'
slack_repo_checksums: str = 'CHECKSUMS.md5'
slack_repo_changelog: str = 'ChangeLog.txt'
@ -58,7 +61,8 @@ class Repositories:
slack_extra_repo: bool = False
slack_extra_repo_name: str = 'slack_extra'
slack_extra_repo_path: Path = Path(repositories_path, slack_extra_repo_name)
slack_extra_repo_mirror = ["https://slackware.uk/slackware/slackware64-15.0/", "extra/"]
slack_extra_repo_mirror_packages: str = ''
slack_extra_repo_mirror_changelog: str = ''
slack_extra_repo_packages: str = 'PACKAGES.TXT'
slack_extra_repo_checksums: str = 'CHECKSUMS.md5'
slack_extra_repo_changelog: str = 'ChangeLog.txt'
@ -67,7 +71,8 @@ class Repositories:
slack_patches_repo: bool = False
slack_patches_repo_name: str = 'slack_patches'
slack_patches_repo_path: Path = Path(repositories_path, slack_patches_repo_name)
slack_patches_repo_mirror = ["https://slackware.uk/slackware/slackware64-15.0/", "patches/"]
slack_patches_repo_mirror_packages: str = ''
slack_patches_repo_mirror_changelog: str = ''
slack_patches_repo_packages: str = 'PACKAGES.TXT'
slack_patches_repo_checksums: str = 'CHECKSUMS.md5'
slack_patches_repo_changelog: str = 'ChangeLog.txt'
@ -76,7 +81,8 @@ class Repositories:
alien_repo: bool = False
alien_repo_name: str = 'alien'
alien_repo_path: Path = Path(repositories_path, alien_repo_name)
alien_repo_mirror = ["https://slackware.nl/people/alien/sbrepos/", "15.0/", "x86_64/"]
alien_repo_mirror_packages: str = ''
alien_repo_mirror_changelog: str = ''
alien_repo_packages: str = 'PACKAGES.TXT'
alien_repo_checksums: str = 'CHECKSUMS.md5'
alien_repo_changelog: str = 'ChangeLog.txt'
@ -85,7 +91,8 @@ class Repositories:
multilib_repo: bool = False
multilib_repo_name: str = 'multilib'
multilib_repo_path: Path = Path(repositories_path, multilib_repo_name)
multilib_repo_mirror = ["https://slackware.nl/people/alien/multilib/", "15.0/"]
multilib_repo_mirror_packages: str = ''
multilib_repo_mirror_changelog: str = ''
multilib_repo_packages: str = 'PACKAGES.TXT'
multilib_repo_checksums: str = 'CHECKSUMS.md5'
multilib_repo_changelog: str = 'ChangeLog.txt'
@ -94,7 +101,8 @@ class Repositories:
restricted_repo: bool = False
restricted_repo_name: str = 'restricted'
restricted_repo_path: Path = Path(repositories_path, restricted_repo_name)
restricted_repo_mirror = ["https://slackware.nl/people/alien/restricted_sbrepos/", "15.0/", "x86_64/"]
restricted_repo_mirror_packages: str = ''
restricted_repo_mirror_changelog: str = ''
restricted_repo_packages: str = 'PACKAGES.TXT'
restricted_repo_checksums: str = 'CHECKSUMS.md5'
restricted_repo_changelog: str = 'ChangeLog.txt'
@ -103,7 +111,8 @@ class Repositories:
gnome_repo: bool = False
gnome_repo_name: str = 'gnome'
gnome_repo_path: Path = Path(repositories_path, gnome_repo_name)
gnome_repo_mirror = ['https://reddoglinux.ddns.net/linux/gnome/43.x/x86_64/']
gnome_repo_mirror_packages: str = ''
gnome_repo_mirror_changelog: str = ''
gnome_repo_packages: str = 'PACKAGES.TXT'
gnome_repo_checksums: str = 'CHECKSUMS.md5'
gnome_repo_changelog: str = 'ChangeLog.txt'
@ -112,7 +121,8 @@ class Repositories:
msb_repo: bool = False
msb_repo_name: str = 'msb'
msb_repo_path: Path = Path(repositories_path, msb_repo_name)
msb_repo_mirror = ["https://slackware.uk/msb/", "15.0/", "1.28/", "x86_64/"]
msb_repo_mirror_packages: str = ''
msb_repo_mirror_changelog: str = ''
msb_repo_packages: str = 'PACKAGES.TXT'
msb_repo_checksums: str = 'CHECKSUMS.md5'
msb_repo_changelog: str = 'ChangeLog.txt'
@ -121,7 +131,8 @@ class Repositories:
csb_repo: bool = False
csb_repo_name: str = 'csb'
csb_repo_path: Path = Path(repositories_path, csb_repo_name)
csb_repo_mirror = ["https://slackware.uk/csb/", "15.0/", "x86_64/"]
csb_repo_mirror_packages: str = ''
csb_repo_mirror_changelog: str = ''
csb_repo_packages: str = 'PACKAGES.TXT'
csb_repo_checksums: str = 'CHECKSUMS.md5'
csb_repo_changelog: str = 'ChangeLog.txt'
@ -130,7 +141,8 @@ class Repositories:
conraid_repo: bool = False
conraid_repo_name: str = 'conraid'
conraid_repo_path: Path = Path(repositories_path, conraid_repo_name)
conraid_repo_mirror = ['https://slackers.it/repository/slackware64-current/']
conraid_repo_mirror_packages: str = ''
conraid_repo_mirror_changelog: str = ''
conraid_repo_packages: str = 'PACKAGES.TXT'
conraid_repo_checksums: str = 'CHECKSUMS.md5'
conraid_repo_changelog: str = 'ChangeLog.txt'
@ -139,7 +151,8 @@ class Repositories:
slackdce_repo: bool = False
slackdce_repo_name: str = 'slackdce'
slackdce_repo_path: Path = Path(repositories_path, slackdce_repo_name)
slackdce_repo_mirror = ['https://slackware.uk/slackdce/15.0/x86_64/']
slackdce_repo_mirror_packages: str = ''
slackdce_repo_mirror_changelog: str = ''
slackdce_repo_packages: str = 'PACKAGES.TXT'
slackdce_repo_checksums: str = 'CHECKSUMS.md5'
slackdce_repo_changelog: str = 'ChangeLog.txt'
@ -148,7 +161,8 @@ class Repositories:
slackonly_repo: bool = False
slackonly_repo_name: str = 'slackonly'
slackonly_repo_path: Path = Path(repositories_path, slackonly_repo_name)
slackonly_repo_mirror = ['https://packages.slackonly.com/pub/packages/15.0-x86_64/']
slackonly_repo_mirror_packages: str = ''
slackonly_repo_mirror_changelog: str = ''
slackonly_repo_packages: str = 'PACKAGES.TXT'
slackonly_repo_checksums: str = 'CHECKSUMS.md5'
slackonly_repo_changelog: str = 'ChangeLog.txt'
@ -157,7 +171,8 @@ class Repositories:
salix_repo: bool = False
salix_repo_name: str = 'salix'
salix_repo_path: Path = Path(repositories_path, salix_repo_name)
salix_repo_mirror = ['https://repo.greeklug.gr/data/pub/linux/salix/x86_64/15.0/']
salix_repo_mirror_packages: str = ''
salix_repo_mirror_changelog: str = ''
salix_repo_packages: str = 'PACKAGES.TXT'
salix_repo_checksums: str = 'CHECKSUMS.md5'
salix_repo_changelog: str = 'ChangeLog.txt'
@ -166,7 +181,8 @@ class Repositories:
salix_extra_repo: bool = False
salix_extra_repo_name: str = 'salix_extra'
salix_extra_repo_path: Path = Path(repositories_path, salix_extra_repo_name)
salix_extra_repo_mirror = ['https://repo.greeklug.gr/data/pub/linux/salix/x86_64/extra-15.0/']
salix_extra_repo_mirror_packages: str = ''
salix_extra_repo_mirror_changelog: str = ''
salix_extra_repo_packages: str = 'PACKAGES.TXT'
salix_extra_repo_checksums: str = 'CHECKSUMS.md5'
salix_extra_repo_changelog: str = 'ChangeLog.txt'
@ -175,7 +191,8 @@ class Repositories:
slackel_repo: bool = False
slackel_repo_name: str = 'slackel'
slackel_repo_path: Path = Path(repositories_path, slackel_repo_name)
slackel_repo_mirror = ['http://www.slackel.gr/repo/x86_64/current/']
slackel_repo_mirror_packages: str = ''
slackel_repo_mirror_changelog: str = ''
slackel_repo_packages: str = 'PACKAGES.TXT'
slackel_repo_checksums: str = 'CHECKSUMS.md5'
slackel_repo_changelog: str = 'ChangeLog.txt'
@ -184,7 +201,8 @@ class Repositories:
slint_repo: bool = False
slint_repo_name: str = 'slint'
slint_repo_path: Path = Path(repositories_path, slint_repo_name)
slint_repo_mirror = ['https://slackware.uk/slint/x86_64/slint-15.0/']
slint_repo_mirror_packages: str = ''
slint_repo_mirror_changelog: str = ''
slint_repo_packages: str = 'PACKAGES.TXT'
slint_repo_checksums: str = 'CHECKSUMS.md5'
slint_repo_changelog: str = 'ChangeLog.txt'
@ -193,7 +211,8 @@ class Repositories:
pprkut_repo: bool = False
pprkut_repo_name: str = 'pprkut'
pprkut_repo_path: Path = Path(repositories_path, pprkut_repo_name)
pprkut_repo_mirror = ['https://repo.liwjatan.org/pprkut/15.0/x86_64/']
pprkut_repo_mirror_packages: str = ''
pprkut_repo_mirror_changelog: str = ''
pprkut_repo_packages: str = 'PACKAGES.TXT'
pprkut_repo_checksums: str = 'CHECKSUMS.md5'
pprkut_repo_changelog: str = 'ChangeLog.txt'
@ -207,62 +226,158 @@ class Repositories:
default_repository: str = repos_config['DEFAULT']['REPO'].lower()
sbo_repo: bool = repos_config['SBO']['ENABLE']
sbo_repo_mirror = repos_config['SBO']['MIRROR']
sbo_repo_url: str = repos_config['SBO']['MIRROR']
sbo_repo_version: str = repos_config['SBO']['VERSION']
sbo_repo_mirror_packages: str = f'{sbo_repo_url}{sbo_repo_version}/'
sbo_repo_mirror_changelog: str = f'{sbo_repo_url}{sbo_repo_version}/'
ponce_repo: bool = repos_config['PONCE']['ENABLE']
ponce_repo_mirror = repos_config['PONCE']['MIRROR']
ponce_repo_url: str = repos_config['PONCE']['MIRROR']
ponce_repo_version: str = repos_config['PONCE']['VERSION']
ponce_repo_mirror_packages: str = f'{ponce_repo_url}{ponce_repo_version}/'
ponce_repo_mirror_changelog: str = f'{ponce_repo_url}{ponce_repo_version}/'
slack_repo: bool = repos_config['SLACK']['ENABLE']
slack_repo_mirror = repos_config['SLACK']['MIRROR']
slack_repo_url: str = repos_config['SLACK']['MIRROR']
slack_repo_version: str = repos_config['SLACK']['VERSION']
slack_repo_arch: str = repos_config['SLACK']['ARCH']
slack_arch: str = ''
if slack_repo_arch == 'x86_64':
slack_arch: str = '64'
slack_repo_mirror_packages: str = f'{slack_repo_url}slackware{slack_arch}-{slack_repo_version}/'
slack_repo_mirror_changelog: str = f'{slack_repo_url}slackware{slack_arch}-{slack_repo_version}/'
slack_extra_repo: bool = repos_config['SLACK_EXTRA']['ENABLE']
slack_extra_repo_mirror = repos_config['SLACK_EXTRA']['MIRROR']
slack_extra_repo_url: str = repos_config['SLACK_EXTRA']['MIRROR']
slack_extra_repo_version: str = repos_config['SLACK_EXTRA']['VERSION']
slack_extra_repo_arch: str = repos_config['SLACK_EXTRA']['ARCH']
slack_extra_arch: str = ''
if slack_extra_repo_arch == 'x86_64':
slack_extra_arch: str = '64'
slack_extra_repo_branch: str = repos_config['SLACK_EXTRA']['BRANCH']
slack_extra_repo_mirror_packages: str = (f'{slack_extra_repo_url}slackware{slack_extra_arch}-'
f'{slack_extra_repo_version}/{slack_extra_repo_branch}/')
slack_extra_repo_mirror_changelog: str = (f'{slack_extra_repo_url}slackware{slack_extra_arch}-'
f'{slack_extra_repo_version}/')
slack_patches_repo: bool = repos_config['SLACK_PATCHES']['ENABLE']
slack_patches_repo_mirror = repos_config['SLACK_PATCHES']['MIRROR']
slack_patches_repo_url: str = repos_config['SLACK_PATCHES']['MIRROR']
slack_patches_repo_version: str = repos_config['SLACK_PATCHES']['VERSION']
slack_patches_repo_arch: str = repos_config['SLACK_PATCHES']['ARCH']
slack_patches_arch: str = ''
if slack_patches_repo_arch == 'x86_64':
slack_patches_arch: str = '64'
slack_patches_repo_branch: str = repos_config['SLACK_PATCHES']['BRANCH']
slack_patches_repo_mirror_packages: str = (f'{slack_patches_repo_url}slackware{slack_patches_arch}-'
f'{slack_patches_repo_version}/{slack_patches_repo_branch}/')
slack_patches_repo_mirror_changelog: str = (f'{slack_patches_repo_url}slackware{slack_patches_arch}-'
f'{slack_patches_repo_version}/')
alien_repo: bool = repos_config['ALIEN']['ENABLE']
alien_repo_mirror = repos_config['ALIEN']['MIRROR']
alien_repo_url: str = repos_config['ALIEN']['MIRROR']
alien_repo_version: str = repos_config['ALIEN']['VERSION']
alien_repo_arch: str = repos_config['ALIEN']['ARCH']
alien_repo_mirror_packages: str = f'{alien_repo_url}{alien_repo_version}/{alien_repo_arch}/'
alien_repo_mirror_changelog: str = alien_repo_url
multilib_repo: bool = repos_config['MULTILIB']['ENABLE']
multilib_repo_mirror = repos_config['MULTILIB']['MIRROR']
multilib_repo_url: str = repos_config['MULTILIB']['MIRROR']
multilib_repo_version: str = repos_config['MULTILIB']['VERSION']
multilib_repo_mirror_packages: str = f'{multilib_repo_url}{multilib_repo_version}/'
multilib_repo_mirror_changelog: str = multilib_repo_url
restricted_repo: bool = repos_config['RESTRICTED']['ENABLE']
restricted_repo_mirror = repos_config['RESTRICTED']['MIRROR']
restricted_repo_url: str = repos_config['RESTRICTED']['MIRROR']
restricted_repo_version: str = repos_config['RESTRICTED']['VERSION']
restricted_repo_arch: str = repos_config['RESTRICTED']['ARCH']
restricted_repo_mirror_packages: str = (f'{restricted_repo_url}{restricted_repo_version}/'
f'{restricted_repo_arch}/')
restricted_repo_mirror_changelog: str = restricted_repo_url
gnome_repo: bool = repos_config['GNOME']['ENABLE']
gnome_repo_mirror = repos_config['GNOME']['MIRROR']
gnome_repo_url: str = repos_config['GNOME']['MIRROR']
gnome_repo_version: str = repos_config['GNOME']['VERSION']
gnome_repo_arch: str = repos_config['GNOME']['ARCH']
gnome_repo_mirror_packages: str = f'{gnome_repo_url}{gnome_repo_version}/{gnome_repo_arch}/'
gnome_repo_mirror_changelog: str = f'{gnome_repo_url}{gnome_repo_version}/{gnome_repo_arch}/'
msb_repo: bool = repos_config['MSB']['ENABLE']
msb_repo_mirror = repos_config['MSB']['MIRROR']
msb_repo_url: str = repos_config['MSB']['MIRROR']
msb_repo_version: str = repos_config['MSB']['VERSION']
msb_repo_branch: str = repos_config['MSB']['BRANCH']
msb_repo_arch: str = repos_config['MSB']['ARCH']
msb_repo_mirror_packages: str = f'{msb_repo_url}{msb_repo_version}/{msb_repo_branch}/{msb_repo_arch}/'
msb_repo_mirror_changelog: str = msb_repo_url
csb_repo: bool = repos_config['CSB']['ENABLE']
csb_repo_mirror = repos_config['CSB']['MIRROR']
csb_repo_url: str = repos_config['CSB']['MIRROR']
csb_repo_version: str = repos_config['CSB']['MIRROR']
csb_repo_arch: str = repos_config['CSB']['ARCH']
csb_repo_mirror_packages: str = f'{csb_repo_url}{csb_repo_version}/{csb_repo_arch}/'
csb_repo_mirror_changelog: str = csb_repo_url
conraid_repo: bool = repos_config['CONRAID']['ENABLE']
conraid_repo_mirror = repos_config['CONRAID']['MIRROR']
conraid_repo_url: str = repos_config['CONRAID']['MIRROR']
conraid_repo_arch: str = repos_config['CONRAID']['ARCH']
conraid_repo_version: str = repos_config['CONRAID']['VERSION']
conraid_arch: str = ''
if conraid_repo_arch == 'x86_64':
conraid_arch: str = '64'
conraid_repo_mirror_packages: str = f'{conraid_repo_url}slackware{conraid_arch}-{conraid_repo_version}/'
conraid_repo_mirror_changelog: str = f'{conraid_repo_url}slackware{conraid_arch}-{conraid_repo_version}/'
slackdce_repo: bool = repos_config['SLACKDCE']['ENABLE']
slackdce_repo_mirror = repos_config['SLACKDCE']['MIRROR']
slackdce_repo_url: str = repos_config['SLACKDCE']['MIRROR']
slackdce_repo_version: str = repos_config['SLACKDCE']['VERSION']
slackdce_repo_arch: str = repos_config['SLACKDCE']['ARCH']
slackdce_repo_mirror_packages: str = f'{slackdce_repo_url}{slackdce_repo_version}/{slackdce_repo_arch}/'
slackdce_repo_mirror_changelog: str = f'{slackdce_repo_url}{slackdce_repo_version}/{slackdce_repo_arch}/'
slackonly_repo: bool = repos_config['SLACKONLY']['ENABLE']
slackonly_repo_mirror = repos_config['SLACKONLY']['MIRROR']
slackonly_repo_url: str = repos_config['SLACKONLY']['MIRROR']
slackonly_repo_version: str = repos_config['SLACKONLY']['VERSION']
slackonly_repo_arch: str = repos_config['SLACKONLY']['ARCH']
slackonly_repo_mirror_packages: str = f'{slackonly_repo_url}{slackonly_repo_version}-{slackonly_repo_arch}/'
slackonly_repo_mirror_changelog: str = (f'{slackonly_repo_url}{slackonly_repo_version}-'
f'{slackonly_repo_arch}/')
salix_repo: bool = repos_config['SALIX']['ENABLE']
salix_repo_mirror = repos_config['SALIX']['MIRROR']
salix_repo_url: str = repos_config['SALIX']['MIRROR']
salix_repo_arch: str = repos_config['SALIX']['ARCH']
salix_repo_version: str = repos_config['SALIX']['VERSION']
salix_repo_mirror_packages: str = f'{salix_repo_url}{salix_repo_arch}/{salix_repo_version}/'
salix_repo_mirror_changelog: str = f'{salix_repo_url}{salix_repo_arch}/{salix_repo_version}/'
salix_extra_repo: bool = repos_config['SALIX_EXTRA']['ENABLE']
salix_extra_repo_mirror = repos_config['SALIX_EXTRA']['MIRROR']
salix_extra_repo_url: str = repos_config['SALIX_EXTRA']['MIRROR']
salix_extra_repo_arch: str = repos_config['SALIX_EXTRA']['ARCH']
salix_extra_repo_branch: str = repos_config['SALIX_EXTRA']['BRANCH']
salix_extra_repo_version: str = repos_config['SALIX_EXTRA']['VERSION']
salix_extra_repo_mirror_packages: str = (f'{salix_extra_repo_url}{salix_extra_repo_arch}/'
f'{salix_extra_repo_branch}-{salix_extra_repo_version}/')
salix_extra_repo_mirror_changelog: str = (f'{salix_extra_repo_url}{salix_extra_repo_arch}/'
f'{salix_extra_repo_branch}-{salix_extra_repo_version}/')
slackel_repo: bool = repos_config['SLACKEL']['ENABLE']
slackel_repo_mirror = repos_config['SLACKEL']['MIRROR']
slackel_repo_url: str = repos_config['SLACKEL']['MIRROR']
slackel_repo_arch: str = repos_config['SLACKEL']['ARCH']
slackel_repo_version: str = repos_config['SLACKEL']['VERSION']
slackel_repo_mirror_packages: str = f'{slackel_repo_url}{slackel_repo_arch}/{slackel_repo_version}/'
slackel_repo_mirror_changelog: str = f'{slackel_repo_url}{slackel_repo_arch}/{slackel_repo_version}/'
slint_repo: bool = repos_config['SLINT']['ENABLE']
slint_repo_mirror = repos_config['SLINT']['MIRROR']
slint_repo_url: str = repos_config['SLINT']['MIRROR']
slint_repo_arch: str = repos_config['SLINT']['ARCH']
slint_repo_version: str = repos_config['SLINT']['VERSION']
slint_repo_mirror_packages: str = f'{slint_repo_url}{slint_repo_arch}/slint-{slint_repo_version}/'
slint_repo_mirror_changelog: str = f'{slint_repo_url}{slint_repo_arch}/slint-{slint_repo_version}/'
pprkut_repo: bool = repos_config['PPRKUT']['ENABLE']
pprkut_repo_mirror = repos_config['PPRKUT']['MIRROR']
pprkut_repo_url: str = repos_config['PPRKUT']['MIRROR']
pprkut_repo_version: str = repos_config['PPRKUT']['VERSION']
pprkut_repo_arch: str = repos_config['PPRKUT']['ARCH']
pprkut_repo_mirror_packages: str = f'{pprkut_repo_url}{pprkut_repo_version}/{pprkut_repo_arch}/'
pprkut_repo_mirror_changelog: str = f'{pprkut_repo_url}{pprkut_repo_version}/{pprkut_repo_arch}/'
except (tomli.TOMLDecodeError, KeyError) as error:
toml_errors.raise_toml_error_message(error, repositories_toml_file)
@ -271,7 +386,8 @@ class Repositories:
sbo_repo_name: {
'enable': sbo_repo,
'path': sbo_repo_path,
'mirror': sbo_repo_mirror,
'mirror_packages': sbo_repo_mirror_packages,
'mirror_changelog': sbo_repo_mirror_changelog,
'slackbuilds_txt': sbo_repo_slackbuilds,
'changelog_txt': sbo_repo_changelog,
'repo_tag': sbo_repo_tag,
@ -280,7 +396,8 @@ class Repositories:
ponce_repo_name: {
'enable': ponce_repo,
'path': ponce_repo_path,
'mirror': ponce_repo_mirror,
'mirror_packages': ponce_repo_mirror_packages,
'mirror_changelog': ponce_repo_mirror_changelog,
'slackbuilds_txt': ponce_repo_slackbuilds,
'changelog_txt': ponce_repo_changelog,
'repo_tag': ponce_repo_tag,
@ -289,7 +406,8 @@ class Repositories:
slack_repo_name: {
'enable': slack_repo,
'path': slack_repo_path,
'mirror': slack_repo_mirror,
'mirror_packages': slack_repo_mirror_packages,
'mirror_changelog': slack_repo_mirror_changelog,
'packages_txt': slack_repo_packages,
'checksums_txt': slack_repo_checksums,
'changelog_txt': slack_repo_changelog,
@ -298,7 +416,8 @@ class Repositories:
slack_extra_repo_name: {
'enable': slack_extra_repo,
'path': slack_extra_repo_path,
'mirror': slack_extra_repo_mirror,
'mirror_packages': slack_extra_repo_mirror_packages,
'mirror_changelog': slack_extra_repo_mirror_changelog,
'packages_txt': slack_extra_repo_packages,
'checksums_txt': slack_extra_repo_checksums,
'changelog_txt': slack_extra_repo_changelog,
@ -307,7 +426,8 @@ class Repositories:
slack_patches_repo_name: {
'enable': slack_patches_repo,
'path': slack_patches_repo_path,
'mirror': slack_patches_repo_mirror,
'mirror_packages': slack_patches_repo_mirror_packages,
'mirror_changelog': slack_patches_repo_mirror_changelog,
'packages_txt': slack_patches_repo_packages,
'checksums_txt': slack_patches_repo_checksums,
'changelog_txt': slack_patches_repo_changelog,
@ -316,7 +436,8 @@ class Repositories:
alien_repo_name: {
'enable': alien_repo,
'path': alien_repo_path,
'mirror': alien_repo_mirror,
'mirror_packages': alien_repo_mirror_packages,
'mirror_changelog': alien_repo_mirror_changelog,
'packages_txt': alien_repo_packages,
'checksums_txt': alien_repo_checksums,
'changelog_txt': alien_repo_changelog,
@ -325,7 +446,8 @@ class Repositories:
multilib_repo_name: {
'enable': multilib_repo,
'path': multilib_repo_path,
'mirror': multilib_repo_mirror,
'mirror_packages': multilib_repo_mirror_packages,
'mirror_changelog': multilib_repo_mirror_changelog,
'packages_txt': multilib_repo_packages,
'checksums_txt': multilib_repo_checksums,
'changelog_txt': multilib_repo_changelog,
@ -334,7 +456,8 @@ class Repositories:
restricted_repo_name: {
'enable': restricted_repo,
'path': restricted_repo_path,
'mirror': restricted_repo_mirror,
'mirror_packages': restricted_repo_mirror_packages,
'mirror_changelog': restricted_repo_mirror_changelog,
'packages_txt': restricted_repo_packages,
'checksums_txt': restricted_repo_checksums,
'changelog_txt': restricted_repo_changelog,
@ -343,7 +466,8 @@ class Repositories:
gnome_repo_name: {
'enable': gnome_repo,
'path': gnome_repo_path,
'mirror': gnome_repo_mirror,
'mirror_packages': gnome_repo_mirror_packages,
'mirror_changelog': gnome_repo_mirror_changelog,
'packages_txt': gnome_repo_packages,
'checksums_txt': gnome_repo_checksums,
'changelog_txt': gnome_repo_changelog,
@ -352,7 +476,8 @@ class Repositories:
msb_repo_name: {
'enable': msb_repo,
'path': msb_repo_path,
'mirror': msb_repo_mirror,
'mirror_packages': msb_repo_mirror_packages,
'mirror_changelog': msb_repo_mirror_changelog,
'packages_txt': msb_repo_packages,
'checksums_txt': msb_repo_checksums,
'changelog_txt': msb_repo_changelog,
@ -361,7 +486,8 @@ class Repositories:
csb_repo_name: {
'enable': csb_repo,
'path': csb_repo_path,
'mirror': csb_repo_mirror,
'mirror_packages': csb_repo_mirror_packages,
'mirror_changelog': csb_repo_mirror_changelog,
'packages_txt': csb_repo_packages,
'checksums_txt': csb_repo_checksums,
'changelog_txt': csb_repo_changelog,
@ -370,7 +496,8 @@ class Repositories:
conraid_repo_name: {
'enable': conraid_repo,
'path': conraid_repo_path,
'mirror': conraid_repo_mirror,
'mirror_packages': conraid_repo_mirror_packages,
'mirror_changelog': conraid_repo_mirror_changelog,
'packages_txt': conraid_repo_packages,
'checksums_txt': conraid_repo_checksums,
'changelog_txt': conraid_repo_changelog,
@ -379,7 +506,8 @@ class Repositories:
slackdce_repo_name: {
'enable': slackdce_repo,
'path': slackdce_repo_path,
'mirror': slackdce_repo_mirror,
'mirror_packages': slackdce_repo_mirror_packages,
'mirror_changelog': slackdce_repo_mirror_changelog,
'packages_txt': slackdce_repo_packages,
'checksums_txt': slackdce_repo_checksums,
'changelog_txt': slackdce_repo_changelog,
@ -388,7 +516,8 @@ class Repositories:
slackonly_repo_name: {
'enable': slackonly_repo,
'path': slackonly_repo_path,
'mirror': slackonly_repo_mirror,
'mirror_packages': slackonly_repo_mirror_packages,
'mirror_changelog': slackonly_repo_mirror_changelog,
'packages_txt': slackonly_repo_packages,
'checksums_txt': slackonly_repo_checksums,
'changelog_txt': slackonly_repo_changelog,
@ -397,7 +526,8 @@ class Repositories:
salix_repo_name: {
'enable': salix_repo,
'path': salix_repo_path,
'mirror': salix_repo_mirror,
'mirror_packages': salix_repo_mirror_packages,
'mirror_changelog': salix_repo_mirror_changelog,
'packages_txt': salix_repo_packages,
'checksums_txt': salix_repo_checksums,
'changelog_txt': salix_repo_changelog,
@ -406,7 +536,8 @@ class Repositories:
salix_extra_repo_name: {
'enable': salix_extra_repo,
'path': salix_extra_repo_path,
'mirror': salix_extra_repo_mirror,
'mirror_packages': salix_extra_repo_mirror_packages,
'mirror_changelog': salix_extra_repo_mirror_changelog,
'packages_txt': salix_extra_repo_packages,
'checksums_txt': salix_extra_repo_checksums,
'changelog_txt': salix_extra_repo_changelog,
@ -415,7 +546,8 @@ class Repositories:
slackel_repo_name: {
'enable': slackel_repo,
'path': slackel_repo_path,
'mirror': slackel_repo_mirror,
'mirror_packages': slackel_repo_mirror_packages,
'mirror_changelog': slackel_repo_mirror_changelog,
'packages_txt': slackel_repo_packages,
'checksums_txt': slackel_repo_checksums,
'changelog_txt': slackel_repo_changelog,
@ -424,7 +556,8 @@ class Repositories:
slint_repo_name: {
'enable': slint_repo,
'path': slint_repo_path,
'mirror': slint_repo_mirror,
'mirror_packages': slint_repo_mirror_packages,
'mirror_changelog': slint_repo_mirror_changelog,
'packages_txt': slint_repo_packages,
'checksums_txt': slint_repo_checksums,
'changelog_txt': slint_repo_changelog,
@ -433,7 +566,8 @@ class Repositories:
pprkut_repo_name: {
'enable': pprkut_repo,
'path': pprkut_repo_path,
'mirror': pprkut_repo_mirror,
'mirror_packages': pprkut_repo_mirror_packages,
'mirror_changelog': pprkut_repo_mirror_changelog,
'packages_txt': pprkut_repo_packages,
'checksums_txt': pprkut_repo_checksums,
'changelog_txt': pprkut_repo_changelog,

View file

@ -49,373 +49,84 @@ class UpdateRepositories(Configs):
for repo in self.repos_for_update:
self.repos_for_update[repo] = True
repositories: dict = {
self.repos.sbo_repo_name: self.sbo_repository,
self.repos.ponce_repo_name: self.ponce_repository,
self.repos.slack_repo_name: self.slack_repository,
self.repos.slack_extra_repo_name: self.slack_extra_repository,
self.repos.slack_patches_repo_name: self.slack_patches_repository,
self.repos.alien_repo_name: self.alien_repository,
self.repos.multilib_repo_name: self.multilib_repository,
self.repos.restricted_repo_name: self.restricted_repository,
self.repos.gnome_repo_name: self.gnome_repository,
self.repos.msb_repo_name: self.msb_repository,
self.repos.csb_repo_name: self.csb_repository,
self.repos.conraid_repo_name: self.conraid_repository,
self.repos.slackdce_repo_name: self.slackdce_repository,
self.repos.slackonly_repo_name: self.slackonly_repository,
self.repos.salix_repo_name: self.salix_repository,
self.repos.salix_extra_repo_name: self.salix_extra_repository,
self.repos.slackel_repo_name: self.slackel_repository,
self.repos.slint_repo_name: self.slint_repository,
self.repos.pprkut_repo_name: self.pprkut_repository
}
if self.option_for_repository:
self.view_downloading_message(self.repository)
repositories[self.repository]()
if self.repository in [self.repos.sbo_repo_name, self.repos.ponce_repo_name]:
self.update_slackbuild_repos(self.repository)
else:
self.update_binary_repos(self.repository)
else:
for repo, update in self.repos_for_update.items():
if update:
self.view_downloading_message(repo)
repositories[repo]()
if self.repository in [self.repos.sbo_repo_name, self.repos.ponce_repo_name]:
self.update_slackbuild_repos(repo)
else:
self.update_binary_repos(repo)
def view_downloading_message(self, repo: str) -> None:
print(f"Syncing with the repository '{self.green}{repo}{self.endc}', please wait...\n")
def slack_repository(self) -> None:
def update_binary_repos(self, repo: str) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.slack_repo_path)
self.utils.remove_file_if_exists(self.repos.slack_repo_path, self.repos.slack_repo_packages)
self.utils.remove_file_if_exists(self.repos.slack_repo_path, self.repos.slack_repo_changelog)
self.utils.remove_file_if_exists(self.repos.slack_repo_path, self.repos.slack_repo_checksums)
install: dict = {
self.repos.slack_repo_name: self.data.install_slack_data,
self.repos.slack_extra_repo_name: self.data.install_slack_extra_data,
self.repos.slack_patches_repo_name: self.data.install_slack_patches_data,
self.repos.alien_repo_name: self.data.install_alien_data,
self.repos.multilib_repo_name: self.data.install_multilib_data,
self.repos.restricted_repo_name: self.data.install_restricted_data,
self.repos.gnome_repo_name: self.data.install_gnome_data,
self.repos.msb_repo_name: self.data.install_msb_data,
self.repos.csb_repo_name: self.data.install_csb_data,
self.repos.conraid_repo_name: self.data.install_conraid_data,
self.repos.slackdce_repo_name: self.data.install_slackdce_data,
self.repos.slackonly_repo_name: self.data.install_slackonly_data,
self.repos.salix_repo_name: self.data.install_salix_data,
self.repos.salix_extra_repo_name: self.data.install_salix_extra_data,
self.repos.slackel_repo_name: self.data.install_slackel_data,
self.repos.slint_repo_name: self.data.install_slint_data,
self.repos.pprkut_repo_name: self.data.install_pprkut_data
}
changelog: str = f'{self.repos.slack_repo_mirror[0]}{self.repos.slack_repo_changelog}'
packages: str = f'{self.repos.slack_repo_mirror[0]}{self.repos.slack_repo_packages}'
checksums: str = f'{self.repos.slack_repo_mirror[0]}{self.repos.slack_repo_checksums}'
self.utils.create_directory(self.repos.repositories[repo]['path'])
self.utils.remove_file_if_exists(self.repos.repositories[repo]['path'], self.repos.repositories[repo]['changelog_txt'])
self.utils.remove_file_if_exists(self.repos.repositories[repo]['path'], self.repos.repositories[repo]['packages_txt'])
self.utils.remove_file_if_exists(self.repos.repositories[repo]['path'], self.repos.repositories[repo]['checksums_txt'])
urls[self.repos.slack_repo_name] = ((changelog, packages, checksums), self.repos.slack_repo_path)
changelog: str = f"{self.repos.repositories[repo]['mirror_changelog']}{self.repos.repositories[repo]['changelog_txt']}"
packages: str = f"{self.repos.repositories[repo]['mirror_packages']}{self.repos.repositories[repo]['packages_txt']}"
checksums: str = f"{self.repos.repositories[repo]['mirror_packages']}{self.repos.repositories[repo]['checksums_txt']}"
urls[repo] = ((changelog, packages, checksums), self.repos.repositories[repo]['path'])
self.download.download(urls)
self.data.install_slack_data()
install[repo]()
def slack_extra_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.slack_extra_repo_path)
self.utils.remove_file_if_exists(self.repos.slack_extra_repo_path, self.repos.slack_extra_repo_changelog)
self.utils.remove_file_if_exists(self.repos.slack_extra_repo_path, self.repos.slack_extra_repo_packages)
self.utils.remove_file_if_exists(self.repos.slack_extra_repo_path, self.repos.slack_extra_repo_checksums)
changelog: str = f'{self.repos.slack_extra_repo_mirror[0]}{self.repos.slack_extra_repo_changelog}'
packages: str = f'{"".join(self.repos.slack_extra_repo_mirror)}{self.repos.slack_extra_repo_packages}'
checksums: str = f'{"".join(self.repos.slack_extra_repo_mirror)}{self.repos.slack_extra_repo_checksums}'
urls[self.repos.slack_extra_repo_name] = ((changelog, packages, checksums), self.repos.slack_extra_repo_path)
self.download.download(urls)
self.data.install_slack_extra_data()
def slack_patches_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.slack_patches_repo_path)
self.utils.remove_file_if_exists(self.repos.slack_patches_repo_path, self.repos.slack_patches_repo_changelog)
self.utils.remove_file_if_exists(self.repos.slack_patches_repo_path, self.repos.slack_patches_repo_packages)
self.utils.remove_file_if_exists(self.repos.slack_patches_repo_path, self.repos.slack_patches_repo_checksums)
changelog: str = f'{self.repos.slack_patches_repo_mirror[0]}{self.repos.slack_patches_repo_changelog}'
packages: str = f'{"".join(self.repos.slack_patches_repo_mirror)}{self.repos.slack_patches_repo_packages}'
checksums: str = f'{"".join(self.repos.slack_patches_repo_mirror)}{self.repos.slack_patches_repo_checksums}'
urls[self.repos.slack_patches_repo_name] = ((changelog, packages, checksums), self.repos.slack_patches_repo_path)
self.download.download(urls)
self.data.install_slack_patches_data()
def alien_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.alien_repo_path)
self.utils.remove_file_if_exists(self.repos.alien_repo_path, self.repos.alien_repo_changelog)
self.utils.remove_file_if_exists(self.repos.alien_repo_path, self.repos.alien_repo_packages)
self.utils.remove_file_if_exists(self.repos.alien_repo_path, self.repos.alien_repo_checksums)
changelog: str = f'{self.repos.alien_repo_mirror[0]}{self.repos.alien_repo_changelog}'
packages: str = f'{"".join(self.repos.alien_repo_mirror)}{self.repos.alien_repo_packages}'
checksums: str = f'{"".join(self.repos.alien_repo_mirror)}{self.repos.alien_repo_checksums}'
urls[self.repos.alien_repo_name] = ((changelog, packages, checksums), self.repos.alien_repo_path)
self.download.download(urls)
self.data.install_alien_data()
def multilib_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.multilib_repo_path)
self.utils.remove_file_if_exists(self.repos.multilib_repo_path, self.repos.multilib_repo_changelog)
self.utils.remove_file_if_exists(self.repos.multilib_repo_path, self.repos.multilib_repo_packages)
self.utils.remove_file_if_exists(self.repos.multilib_repo_path, self.repos.multilib_repo_checksums)
changelog: str = f'{self.repos.multilib_repo_mirror[0]}{self.repos.multilib_repo_changelog}'
packages: str = f'{"".join(self.repos.multilib_repo_mirror)}{self.repos.multilib_repo_packages}'
checksums: str = f'{"".join(self.repos.multilib_repo_mirror)}{self.repos.multilib_repo_checksums}'
urls[self.repos.multilib_repo_name] = ((changelog, packages, checksums), self.repos.multilib_repo_path)
self.download.download(urls)
self.data.install_multilib_data()
def restricted_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.restricted_repo_path)
self.utils.remove_file_if_exists(self.repos.restricted_repo_path, self.repos.restricted_repo_changelog)
self.utils.remove_file_if_exists(self.repos.restricted_repo_path, self.repos.restricted_repo_packages)
self.utils.remove_file_if_exists(self.repos.restricted_repo_path, self.repos.restricted_repo_checksums)
changelog: str = f'{self.repos.restricted_repo_mirror[0]}{self.repos.restricted_repo_changelog}'
packages: str = f'{"".join(self.repos.restricted_repo_mirror)}{self.repos.restricted_repo_packages}'
checksums: str = f'{"".join(self.repos.restricted_repo_mirror)}{self.repos.restricted_repo_checksums}'
urls[self.repos.restricted_repo_name] = ((changelog, packages, checksums), self.repos.restricted_repo_path)
self.download.download(urls)
self.data.install_restricted_data()
def gnome_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.gnome_repo_path)
self.utils.remove_file_if_exists(self.repos.gnome_repo_path, self.repos.gnome_repo_changelog)
self.utils.remove_file_if_exists(self.repos.gnome_repo_path, self.repos.gnome_repo_packages)
self.utils.remove_file_if_exists(self.repos.gnome_repo_path, self.repos.gnome_repo_checksums)
changelog: str = f'{self.repos.gnome_repo_mirror[0]}{self.repos.gnome_repo_changelog}'
packages: str = f'{self.repos.gnome_repo_mirror[0]}{self.repos.gnome_repo_packages}'
checksums: str = f'{self.repos.gnome_repo_mirror[0]}{self.repos.gnome_repo_checksums}'
urls[self.repos.gnome_repo_name] = ((changelog, packages, checksums), self.repos.gnome_repo_path)
self.download.download(urls)
self.data.install_gnome_data()
def msb_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.msb_repo_path)
self.utils.remove_file_if_exists(self.repos.msb_repo_path, self.repos.msb_repo_changelog)
self.utils.remove_file_if_exists(self.repos.msb_repo_path, self.repos.msb_repo_packages)
self.utils.remove_file_if_exists(self.repos.msb_repo_path, self.repos.msb_repo_checksums)
changelog: str = f'{self.repos.msb_repo_mirror[0]}{self.repos.msb_repo_changelog}'
packages: str = f'{"".join(self.repos.msb_repo_mirror)}{self.repos.msb_repo_packages}'
checksums: str = f'{"".join(self.repos.msb_repo_mirror)}{self.repos.msb_repo_checksums}'
urls[self.repos.msb_repo_name] = ((changelog, packages, checksums), self.repos.msb_repo_path)
self.download.download(urls)
self.data.install_msb_data()
def csb_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.csb_repo_path)
self.utils.remove_file_if_exists(self.repos.csb_repo_path, self.repos.csb_repo_packages)
self.utils.remove_file_if_exists(self.repos.csb_repo_path, self.repos.csb_repo_changelog)
self.utils.remove_file_if_exists(self.repos.csb_repo_path, self.repos.csb_repo_checksums)
changelog: str = f'{"".join(self.repos.csb_repo_mirror)}{self.repos.csb_repo_changelog}'
packages: str = f'{"".join(self.repos.csb_repo_mirror)}{self.repos.csb_repo_packages}'
checksums: str = f'{"".join(self.repos.csb_repo_mirror)}{self.repos.csb_repo_checksums}'
urls[self.repos.csb_repo_name] = ((changelog, packages, checksums), self.repos.csb_repo_path)
self.download.download(urls)
self.data.install_csb_data()
def conraid_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.conraid_repo_path)
self.utils.remove_file_if_exists(self.repos.conraid_repo_path, self.repos.conraid_repo_changelog)
self.utils.remove_file_if_exists(self.repos.conraid_repo_path, self.repos.conraid_repo_packages)
self.utils.remove_file_if_exists(self.repos.conraid_repo_path, self.repos.conraid_repo_checksums)
changelog: str = f'{self.repos.conraid_repo_mirror[0]}{self.repos.conraid_repo_changelog}'
packages: str = f'{self.repos.conraid_repo_mirror[0]}{self.repos.conraid_repo_packages}'
checksums: str = f'{self.repos.conraid_repo_mirror[0]}{self.repos.conraid_repo_checksums}'
urls[self.repos.conraid_repo_name] = ((changelog, packages, checksums), self.repos.conraid_repo_path)
self.download.download(urls)
self.data.install_conraid_data()
def slackdce_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.slackdce_repo_path)
self.utils.remove_file_if_exists(self.repos.slackdce_repo_path, self.repos.slackdce_repo_changelog)
self.utils.remove_file_if_exists(self.repos.slackdce_repo_path, self.repos.slackdce_repo_packages)
self.utils.remove_file_if_exists(self.repos.slackdce_repo_path, self.repos.slackdce_repo_checksums)
changelog: str = f'{self.repos.slackdce_repo_mirror[0]}{self.repos.slackdce_repo_changelog}'
packages: str = f'{self.repos.slackdce_repo_mirror[0]}{self.repos.slackdce_repo_packages}'
checksums: str = f'{self.repos.slackdce_repo_mirror[0]}{self.repos.slackdce_repo_checksums}'
urls[self.repos.slackdce_repo_name] = ((changelog, packages, checksums), self.repos.slackdce_repo_path)
self.download.download(urls)
self.data.install_slackdce_data()
def slackonly_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.slackonly_repo_path)
self.utils.remove_file_if_exists(self.repos.slackonly_repo_path, self.repos.slackonly_repo_changelog)
self.utils.remove_file_if_exists(self.repos.slackonly_repo_path, self.repos.slackonly_repo_packages)
self.utils.remove_file_if_exists(self.repos.slackonly_repo_path, self.repos.slackonly_repo_checksums)
changelog: str = f'{self.repos.slackonly_repo_mirror[0]}{self.repos.slackonly_repo_changelog}'
packages: str = f'{self.repos.slackonly_repo_mirror[0]}{self.repos.slackonly_repo_packages}'
checksums: str = f'{self.repos.slackonly_repo_mirror[0]}{self.repos.slackonly_repo_checksums}'
urls[self.repos.slackonly_repo_name] = ((changelog, packages, checksums), self.repos.slackonly_repo_path)
self.download.download(urls)
self.data.install_slackonly_data()
def salix_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.salix_repo_path)
self.utils.remove_file_if_exists(self.repos.salix_repo_path, self.repos.salix_repo_changelog)
self.utils.remove_file_if_exists(self.repos.salix_repo_path, self.repos.salix_repo_packages)
self.utils.remove_file_if_exists(self.repos.salix_repo_path, self.repos.salix_repo_checksums)
changelog: str = f'{self.repos.salix_repo_mirror[0]}{self.repos.salix_repo_changelog}'
packages: str = f'{self.repos.salix_repo_mirror[0]}{self.repos.salix_repo_packages}'
checksums: str = f'{self.repos.salix_repo_mirror[0]}{self.repos.salix_repo_checksums}'
urls[self.repos.salix_repo_name] = ((changelog, packages, checksums), self.repos.salix_repo_path)
self.download.download(urls)
self.data.install_salix_data()
def salix_extra_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.salix_extra_repo_path)
self.utils.remove_file_if_exists(self.repos.salix_extra_repo_path, self.repos.salix_extra_repo_changelog)
self.utils.remove_file_if_exists(self.repos.salix_extra_repo_path, self.repos.salix_extra_repo_packages)
self.utils.remove_file_if_exists(self.repos.salix_extra_repo_path, self.repos.salix_extra_repo_checksums)
changelog: str = f'{self.repos.salix_extra_repo_mirror[0]}{self.repos.salix_extra_repo_changelog}'
packages: str = f'{self.repos.salix_extra_repo_mirror[0]}{self.repos.salix_extra_repo_packages}'
checksums: str = f'{self.repos.salix_extra_repo_mirror[0]}{self.repos.salix_extra_repo_checksums}'
urls[self.repos.salix_extra_repo_name] = ((changelog, packages, checksums), self.repos.salix_extra_repo_path)
self.download.download(urls)
self.data.install_salix_extra_data()
def slackel_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.slackel_repo_path)
self.utils.remove_file_if_exists(self.repos.slackel_repo_path, self.repos.slackel_repo_changelog)
self.utils.remove_file_if_exists(self.repos.slackel_repo_path, self.repos.slackel_repo_packages)
self.utils.remove_file_if_exists(self.repos.slackel_repo_path, self.repos.slackel_repo_checksums)
changelog: str = f'{self.repos.slackel_repo_mirror[0]}{self.repos.slackel_repo_changelog}'
packages: str = f'{self.repos.slackel_repo_mirror[0]}{self.repos.slackel_repo_packages}'
checksums: str = f'{self.repos.slackel_repo_mirror[0]}{self.repos.slackel_repo_checksums}'
urls[self.repos.slackel_repo_name] = ((changelog, packages, checksums), self.repos.slackel_repo_path)
self.download.download(urls)
self.data.install_slackel_data()
def slint_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.slint_repo_path)
self.utils.remove_file_if_exists(self.repos.slint_repo_path, self.repos.slint_repo_changelog)
self.utils.remove_file_if_exists(self.repos.slint_repo_path, self.repos.slint_repo_packages)
self.utils.remove_file_if_exists(self.repos.slint_repo_path, self.repos.slint_repo_checksums)
changelog: str = f'{self.repos.slint_repo_mirror[0]}{self.repos.slint_repo_changelog}'
packages: str = f'{self.repos.slint_repo_mirror[0]}{self.repos.slint_repo_packages}'
checksums: str = f'{self.repos.slint_repo_mirror[0]}{self.repos.slint_repo_checksums}'
urls[self.repos.slint_repo_name] = ((changelog, packages, checksums), self.repos.slint_repo_path)
self.download.download(urls)
self.data.install_slint_data()
def pprkut_repository(self) -> None:
urls: dict = {}
self.utils.create_directory(self.repos.pprkut_repo_path)
self.utils.remove_file_if_exists(self.repos.pprkut_repo_path, self.repos.pprkut_repo_changelog)
self.utils.remove_file_if_exists(self.repos.pprkut_repo_path, self.repos.pprkut_repo_packages)
self.utils.remove_file_if_exists(self.repos.pprkut_repo_path, self.repos.pprkut_repo_checksums)
changelog: str = f'{self.repos.pprkut_repo_mirror[0]}{self.repos.pprkut_repo_changelog}'
packages: str = f'{self.repos.pprkut_repo_mirror[0]}{self.repos.pprkut_repo_packages}'
checksums: str = f'{self.repos.pprkut_repo_mirror[0]}{self.repos.pprkut_repo_checksums}'
urls[self.repos.pprkut_repo_name] = ((changelog, packages, checksums), self.repos.pprkut_repo_path)
self.download.download(urls)
self.data.install_pprkut_data()
def ponce_repository(self) -> None:
def update_slackbuild_repos(self, repo: str) -> None:
""" Update the slackbuild repositories. """
self.utils.create_directory(self.repos.ponce_repo_path)
self.utils.remove_file_if_exists(self.repos.ponce_repo_path, self.repos.ponce_repo_slackbuilds)
self.utils.remove_file_if_exists(self.repos.ponce_repo_path, self.repos.ponce_repo_changelog)
self.utils.create_directory(self.repos.repositories[repo]['path'])
self.utils.remove_file_if_exists(self.repos.repositories[repo]['path'],
self.repos.repositories[repo]['slackbuilds_txt'])
self.utils.remove_file_if_exists(self.repos.repositories[repo]['path'],
self.repos.repositories[repo]['changelog_txt'])
lftp_command: str = f'lftp {self.lftp_mirror_options} {self.repos.ponce_repo_mirror[0]} {self.repos.ponce_repo_path}'
lftp_command: str = (f"lftp {self.lftp_mirror_options} {self.repos.repositories[repo]['mirror_packages']} "
f"{self.repos.repositories[repo]['path']}")
self.multi_process.process(lftp_command)
# It checks if there is the SLACKBUILDS.TXT file, otherwise going to create it.
if not Path(self.repos.ponce_repo_path, self.repos.ponce_repo_slackbuilds).is_file():
self.generate.slackbuild_file(self.repos.ponce_repo_path, self.repos.ponce_repo_slackbuilds)
# It checks if there is a SLACKBUILDS.TXT file, otherwise it going to create one.
if not Path(self.repos.repositories[repo]['path'],
self.repos.repositories[repo]['slackbuilds_txt']).is_file():
self.generate.slackbuild_file(self.repos.repositories[repo]['path'],
self.repos.repositories[repo]['slackbuilds_txt'])
self.data.install_ponce_data()
install: dict = {
self.repos.sbo_repo_name: self.data.install_sbo_data,
self.repos.ponce_repo_name: self.data.install_ponce_data
}
def sbo_repository(self) -> None:
self.utils.create_directory(self.repos.sbo_repo_path)
self.utils.remove_file_if_exists(self.repos.sbo_repo_path, self.repos.sbo_repo_slackbuilds)
self.utils.remove_file_if_exists(self.repos.sbo_repo_path, self.repos.sbo_repo_changelog)
lftp_command: str = f'lftp {self.lftp_mirror_options} {self.repos.sbo_repo_mirror[0]} {self.repos.sbo_repo_path}'
self.multi_process.process(lftp_command)
# It checks if there is the SLACKBUILDS.TXT file, otherwise going to create it.
if not Path(self.repos.sbo_repo_path, self.repos.sbo_repo_slackbuilds).is_file():
self.generate.slackbuild_file(self.repos.sbo_repo_path, self.repos.sbo_repo_slackbuilds)
self.data.install_sbo_data()
install[repo]()