mirror of
https://gitlab.com/dslackw/slpkg.git
synced 2024-11-16 07:47:35 +01:00
Added lftp option
This commit is contained in:
parent
b42865cbb4
commit
1e506912b7
4 changed files with 16 additions and 6 deletions
|
@ -1,5 +1,9 @@
|
|||
## slpkg - ChangeLog
|
||||
|
||||
### 4.9.4 - 04/12/2023
|
||||
- Added:
|
||||
* lftp_exclude extra option to it's ignore some not useful files
|
||||
|
||||
### 4.9.3 - 28/11/2023
|
||||
- Updated:
|
||||
* [Tracking] Returns the complete list of dependencies of a package
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# This is the general configuration file of slpkg:
|
||||
# /etc/slpkg/slpkg.toml
|
||||
# Date: 24/04/2023, Version: 4.8.3
|
||||
# Date: 04/12/2023, Version: 4.9.4
|
||||
|
||||
[CONFIGS]
|
||||
|
||||
|
@ -107,8 +107,12 @@ CURL_OPTIONS = ""
|
|||
# Lftp donwloader options.
|
||||
LFTP_GET_OPTIONS = "-c get -e"
|
||||
|
||||
# Lftp mirror options are used to synchronize with the repositories.
|
||||
# Lftp mirror options are used to synchronize with the SBo and Ponce repositories
|
||||
# or for the locals repositories.
|
||||
LFTP_MIRROR_OPTIONS = "-c mirror --parallel=100 --only-newer"
|
||||
# Addition extra option for lftp command to exclude some not useful files
|
||||
# from SBo repository.
|
||||
LFTP_EXCLUDE = "-X SLACKBUILDS.TXT.gz -X CHECKSUMS.md5.asc -X 'TAGS.txt*' -X '*.tar.gz*'"
|
||||
|
||||
# If you are going to use a proxy server, try to fill in these variables.
|
||||
# Choose between http or socks proxy type.
|
||||
|
|
|
@ -39,6 +39,7 @@ class Configs:
|
|||
curl_options: str = ''
|
||||
lftp_get_options: str = '-c get -e'
|
||||
lftp_mirror_options: str = '-c mirror --parallel=100 --only-newer'
|
||||
lftp_exclude: str = "-X SLACKBUILDS.TXT.gz -X CHECKSUMS.md5.asc -X 'TAGS.txt*' -X '*.tar.gz*'"
|
||||
silent_mode: bool = True
|
||||
ascii_characters: bool = True
|
||||
ask_question: bool = True
|
||||
|
@ -78,6 +79,7 @@ class Configs:
|
|||
curl_options: str = config['CURL_OPTIONS']
|
||||
lftp_get_options: str = config['LFTP_GET_OPTIONS']
|
||||
lftp_mirror_options: str = config['LFTP_MIRROR_OPTIONS']
|
||||
lftp_exclude: str = config['LFTP_EXCLUDE']
|
||||
silent_mode: bool = config['SILENT_MODE']
|
||||
ascii_characters: bool = config['ASCII_CHARACTERS']
|
||||
file_list_suffix: str = config['FILE_LIST_SUFFIX']
|
||||
|
|
|
@ -632,8 +632,8 @@ class UpdateRepositories(Configs):
|
|||
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)
|
||||
|
||||
lftp_command: str = (f'lftp {self.lftp_mirror_options} {self.repos.ponce_repo_mirror[0]} '
|
||||
f'{self.repos.ponce_repo_path}')
|
||||
lftp_command: str = (f'lftp {self.lftp_mirror_options} {self.lftp_exclude} '
|
||||
f'{self.repos.ponce_repo_mirror[0]} {self.repos.ponce_repo_path}')
|
||||
|
||||
self.utils.process(lftp_command)
|
||||
|
||||
|
@ -651,8 +651,8 @@ class UpdateRepositories(Configs):
|
|||
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]} '
|
||||
f'{self.repos.sbo_repo_path}')
|
||||
lftp_command: str = (f'lftp {self.lftp_mirror_options} {self.lftp_exclude} '
|
||||
f'{self.repos.sbo_repo_mirror[0]} {self.repos.sbo_repo_path}')
|
||||
|
||||
self.utils.process(lftp_command)
|
||||
|
||||
|
|
Loading…
Reference in a new issue