From 10230a06ccb73735844be6fd8280c1d1a774d707 Mon Sep 17 00:00:00 2001 From: piterpunk Date: Wed, 5 Apr 2023 19:48:37 -0300 Subject: [PATCH 1/2] Minor formatting fixes --- files/slackpkg.conf.5 | 6 +++++- files/slackpkg.conf.new | 4 +--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/files/slackpkg.conf.5 b/files/slackpkg.conf.5 index e202f85..e47da8b 100644 --- a/files/slackpkg.conf.5 +++ b/files/slackpkg.conf.5 @@ -102,7 +102,11 @@ is /var/lib/slackpkg. .B DOWNLOADER .br Selects the download application slackpkg will use to fetch files. -Current options are \fBcurl\fR or \fBwget\fR. Default is wget. +Current options are "curl" or "wget". + +The default value of +.B DOWNLOADER +is "wget" .TP 5 .B CURLFLAGS diff --git a/files/slackpkg.conf.new b/files/slackpkg.conf.new index d96b759..96a4173 100644 --- a/files/slackpkg.conf.new +++ b/files/slackpkg.conf.new @@ -70,9 +70,7 @@ TEMP=/var/cache/packages # Package lists, file lists, and others will be stored in WORKDIR: WORKDIR=/var/lib/slackpkg -# Use curl or wget for Downloading (wget is default) -#DOWNLOADER=curl - +# Use curl or wget for downloading (wget is default) DOWNLOADER=wget # Special options for curl From e0b0a089133878a29135cbcffe52ae3cc5baa92c Mon Sep 17 00:00:00 2001 From: piterpunk Date: Wed, 5 Apr 2023 20:16:31 -0300 Subject: [PATCH 2/2] Detects if installed system is Slackware Current If the installed system is Slackware Current, creates the `/var/lib/slackpkg/current` file by default, saving the user from being asked about using a `current` mirror in a Slackware stable install. --- files/core-functions.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/files/core-functions.sh b/files/core-functions.sh index 8245478..4a58cd8 100644 --- a/files/core-functions.sh +++ b/files/core-functions.sh @@ -64,6 +64,12 @@ function system_setup() { # Create $WORKDIR just in case mkdir -p "${WORKDIR}" + # Set the "current" flag if system is running Slackware Current + if [ -n "$(echo $SLACKWARE_VERSION | sed -ne 's/.*\(+\|current\)$/\1/pi')" ] && \ + [ ! -e ${WORKDIR}/current ]; then + touch ${WORKDIR}/current + fi + # Select the command to fetch files and packages from network sources if [ "$DOWNLOADER" = "curl" ]; then DOWNLOADER="curl ${CURLFLAGS} -o" @@ -188,7 +194,7 @@ as example or overwrite it with slackpkg.conf.new.\n\ if [ "$ARCH" = "none" ] && [ "$CMD" != "new-config" ]; then echo -e "\ \nThe ARCH values in slackpkg.conf are now different. You can remove\n\ -ARCH from there, and slackpkg you use your current ARCH or you can look\n\ +ARCH from there, and slackpkg will use your current ARCH or you can look\n\ at slackpkg.conf.new or slackpkg.conf manual page to see the new valid\n\ ARCH values\n" cleanup