From 89f2a014d99aad7598a4578d2007cb0028601f2b Mon Sep 17 00:00:00 2001 From: Daniel Naftalovich Date: Tue, 7 Feb 2017 19:21:49 +0200 Subject: [PATCH 1/2] Added curl fallback for package installation --- apt-cyg | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/apt-cyg b/apt-cyg index 84a2d5f..2f41358 100755 --- a/apt-cyg +++ b/apt-cyg @@ -122,10 +122,15 @@ function wget { if command wget -h &>/dev/null then command wget "$@" - else + elif + then warn wget is not installed, using lynx as fallback set "${*: -1}" lynx -source "$1" > "${1##*/}" + else + warn wget and lynx not installed, using curl as fallback + set "${*: -1}" + curl -sL "$1" > "${1##*/}" fi } From 7ac7bcdfe9b7d1066d5bf75f23081115bfa9059c Mon Sep 17 00:00:00 2001 From: Daniel Naftalovich Date: Tue, 7 Feb 2017 19:23:36 +0200 Subject: [PATCH 2/2] Changed apt-cyg installation to use curl --- readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/readme.md b/readme.md index 5b44a03..11285d6 100644 --- a/readme.md +++ b/readme.md @@ -65,7 +65,7 @@ Quick start apt-cyg is a simple script. To install: - lynx -source rawgit.com/transcode-open/apt-cyg/master/apt-cyg > apt-cyg + curl -L rawgit.com/transcode-open/apt-cyg/master/apt-cyg > apt-cyg install apt-cyg /bin Example use of apt-cyg: