From 0fa1b3834567b830b91ece71bbddb2ef4ba5ea16 Mon Sep 17 00:00:00 2001 From: Dimitris Zlatanidis Date: Thu, 6 Apr 2023 13:53:57 +0300 Subject: [PATCH] Updated for wget2 --- configs/slpkg.toml | 2 +- slpkg/downloader.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/configs/slpkg.toml b/configs/slpkg.toml index b280b7a9..27112ab1 100644 --- a/configs/slpkg.toml +++ b/configs/slpkg.toml @@ -43,7 +43,7 @@ REMOVEPKG = "removepkg" # You can choose a downloader among wget, curl and lftp. - # Default is wget. [wget/curl/lftp] + # Default is wget. [wget/wget2/curl/lftp] DOWNLOADER = "wget" # Wget downloader options. # -c, --continue: resume getting a partially-downloaded file. diff --git a/slpkg/downloader.py b/slpkg/downloader.py index 20be7ac6..463f5295 100644 --- a/slpkg/downloader.py +++ b/slpkg/downloader.py @@ -43,7 +43,7 @@ class Downloader(Configs): command: str = '' filename: str = url.split('/')[-1] - if self.downloader == 'wget': + if self.downloader in ['wget', 'wget2']: command: str = f'{self.downloader} {self.wget_options} --directory-prefix={self.path} "{url}"' elif self.downloader == 'curl':