Skip to content

Commit

Permalink
Merge pull request #31 from piterpunk/detect_if_system_is_running_cur…
Browse files Browse the repository at this point in the history
…rent
  • Loading branch information
piterpunk authored Apr 10, 2023
2 parents c137377 + e0b0a08 commit a64693d
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 5 deletions.
8 changes: 7 additions & 1 deletion files/core-functions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down Expand Up @@ -190,7 +196,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
Expand Down
6 changes: 5 additions & 1 deletion files/slackpkg.conf.5
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
4 changes: 1 addition & 3 deletions files/slackpkg.conf.new
Original file line number Diff line number Diff line change
Expand Up @@ -74,9 +74,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
Expand Down

0 comments on commit a64693d

Please sign in to comment.