Current -devel is the same of -1.2.0, so I will merge with master

before refork.
This commit is contained in:
Matteo Rossini 2013-12-09 14:30:20 +01:00
parent 4eca3dabea
commit c1a543c828
8 changed files with 152 additions and 38 deletions

View file

@ -1,3 +1,6 @@
Version 20131209.1 - 09/Nov/2013
- Current -devel is the same of -1.2.0
Version 20131120.1 - 20/Nov/2013
- Moved notify messages in a dedicated configuration file and added
ENABLENOTIFY to enable/disable it

View file

@ -1,3 +1,6 @@
Version 20131209.1 - 09/Nov/2013
- Current -devel is the same of -1.2.0
Version 20131120.1 - 20/Nov/2013
- Moved notify messages in a dedicated configuration file and added
ENABLENOTIFY to enable/disable it

View file

@ -21,10 +21,17 @@ for any damage that may be caused to your computer.
CONFIGURATION
For the basic configuration:
* Edit /etc/slackpkg/slackpkgplus.conf
* Uncomment one or more mirrors and add them to the REPOPLUS list
* Optionally, set PKGS_PRIORITY to give priority order for packages present in
multiple repositories
Note that packages in these repository will not listed if they are present in
the official repositories (see below).
* Optionally, set PKGS_PRIORITY to give priority order for single packages
present in multiple repositories or to allow repositories to override
official slackware packages
For a list of supported repositories see repositories.txt, but you can also
add others yourself.
@ -131,10 +138,10 @@ PRIORITY CONFIGURATION
When a package is present in more than one repository, the package will be
searched for in the following order:
1) as listed in PKGS_PRIORITY
1) as listed in PKGS_PRIORITY (allow to override official packages)
2) as listed in an official Slackware repository
(configured in /etc/slackpkg/mirrors)
3) as listed in REPOPLUS
3) as listed in REPOPLUS (deny to override official packages)
4) all others defined in MIRRORPLUS
PKGS_PRIORITY syntax:
@ -154,7 +161,7 @@ MULTILIB
If you want to use a multilib system, you can automatically configure the
multilib repository in slackpkgplus.conf and install multilib simply by running:
# /usr/doc/slackpkg+-1.0/setupmultilib.sh
# /usr/doc/slackpkg+-1.2.0/setupmultilib.sh
To configure multilib manually (e.g. if you have installed multilib already),
uncomment the correct "MIRRORPLUS['multilib']=...",
@ -298,6 +305,85 @@ metadata!!
------
NOTIFICATIONS
Some package require special post-installation activity as upgrading a related
package or rebuilt kernel modules or change a custom configuration. A user may
forgot to do this, especially in large updates. The notification functionality
help the user to remember it. In /etc/slackpkg/notifymsg.conf you can define
some custom event. See documentation in that file. Events may be VERY custom
(on kde upgrde remember me to call my friends ;), or the more useful
"on kernel upgrade remember to recompile all driver modules"
You may enable this function by setting "ENABLENOTIFY=on" in slackpkgplus.conf
-----
WGET Options
slackpkg+ uses wget to download packages and metadata.
You can use the WGETOPTS setting to pass options to wget.
By default when an url is unreachable wget - after a long timeout - retry to
download so if a repository is unreacheble you should remove it from your
configuration file.
As workaround you can add the options WGETOPTS="--timeout=5 --tries=1"
in slackpkgplus.conf
-----
ALLOW32BIT
By default slackpkg+ deny to install 32bit packages on a 64bit system.
Set ALLOW32BIT=on to allow slackpkg+ to install 32bit packages on a 64bit slackware
installation (possibly unsafe). Please, do not install both 32 and 64bit of the same
package to avoid problems, and NEVER upgrade exitant 64bit packages with relative 32bit
package.
Do not forget to install the multilibs.
-----
GREYLIST
Sometime you may want that slackpkg+ does not install some package in the upgrade-all
process. To do that you must uncheck the package everytime or add it in the
'blacklist' file. The first method may be onerous when you use upgrade-all frequently.
The second method does not allow you to know which package version is available.
A thirdy method is to put it in the 'graylist' file.
All packages listed in graylist will be available to install and listed in slackpkg
dialog, but they will be unchecked by default so you are sure to not install it
wrongly.
You may decide also to greylist one entire repository. A good idea is to greylist
all thirdy party repository so an upgrade-all automatically upgrade official
slackware packages but force you to review all other packages so to be sure on what
you install.
-----
INSTALL LOG
Slackpkg+ now create a log of all installed packages in /var/lib/slackpkg/install.log
and try to add in this log from which repository you have downloaded the file.
This help you to track your slackware installation.
You are encouraged to run '/usr/lib/slackpkg/makeinstlog.sh -t' (this may take a few)
to initialize the log (it will create /var/lib/slackpkg/install.log.tmp). The '-t'
param add the repository name from which the packages was downloaded, but it may fails,
so you are encouraged to review the file before rename it in install.log.
Note that you can edit manually to modify or add informations.
At every slackpkg install/upgrade/remove invocation, a new log will be added.
At every slackpkg update invocation, a fast list rebuild will be done.
-----
FURTHER INFORMATION
The AlienBOB article about slackpkg+:

View file

@ -6,3 +6,12 @@
# Don't use *full* regex here, because all of the following
# will be checked for the regex: series, name, version, arch,
# build, fullname and repository name.
#
# Also you may want to greylist ALL slackpkgplus repository;
# useful if you want to run slackpkg install alienbob and select
# only the wanted package (instead de-select all unwanted):
#SLACKPKGPLUS_.*
#
# You may want to greylist kde and/or kdei
#kde
#kdei

View file

@ -6,7 +6,8 @@ declare -A MIRRORPLUS
declare -A NOTIFYMSG
if [ -e /etc/slackpkg/slackpkgplus.conf ];then
# You can override ALLOW32BIT WGETOPTS SLACKPKGPLUS VERBOSE USEBL from command-line
# You can override GREYLIST WGETOPTS SLACKPKGPLUS VERBOSE USEBL ALLOW32BIT from command-line
EXTGREYLIST=$GREYLIST
EXTALLOW32BIT=$ALLOW32BIT
EXTSLACKPKGPLUS=$SLACKPKGPLUS
EXTVERBOSE=$VERBOSE
@ -15,6 +16,7 @@ if [ -e /etc/slackpkg/slackpkgplus.conf ];then
. /etc/slackpkg/slackpkgplus.conf
GREYLIST=${EXTGREYLIST:-$GREYLIST}
ALLOW32BIT=${EXTALLOW32BIT:-$ALLOW32BIT}
SLACKPKGPLUS=${EXTSLACKPKGPLUS:-$SLACKPKGPLUS}
VERBOSE=${EXTVERBOSE:-$VERBOSE}
@ -32,7 +34,7 @@ fi
if [ "$SLACKPKGPLUS" = "on" ];then
SPKGPLUS_VERSION="20131120.1"
SPKGPLUS_VERSION="1.2.0"
VERSION="$VERSION / slackpkg+ $SPKGPLUS_VERSION"
@ -243,11 +245,11 @@ if [ "$SLACKPKGPLUS" = "on" ];then
X86_64=$(ls /var/log/packages/aaa_base*x86_64*|head -1 2>/dev/null)
for PREPO in $REPOPLUS;do
if [ ! -z "$X86_64" ];then
if [ "$ALLOW32BIT" == "on" ];then
egrep -e ^[a-f0-9]{32} ${TMPDIR}/CHECKSUMS.md5-$PREPO|egrep -v -- "-(arm)-" |sed -r "s# \./# ./SLACKPKGPLUS_$PREPO/#" >> ${TMPDIR}/CHECKSUMS.md5
else
egrep -e ^[a-f0-9]{32} ${TMPDIR}/CHECKSUMS.md5-$PREPO|egrep -v -- "-(i[3456]86|arm)-" |sed -r "s# \./# ./SLACKPKGPLUS_$PREPO/#" >> ${TMPDIR}/CHECKSUMS.md5
fi
if [ "$ALLOW32BIT" == "on" ];then
egrep -e ^[a-f0-9]{32} ${TMPDIR}/CHECKSUMS.md5-$PREPO|egrep -v -- "-(arm)-" |sed -r "s# \./# ./SLACKPKGPLUS_$PREPO/#" >> ${TMPDIR}/CHECKSUMS.md5
else
egrep -e ^[a-f0-9]{32} ${TMPDIR}/CHECKSUMS.md5-$PREPO|egrep -v -- "-(i[3456]86|arm)-" |sed -r "s# \./# ./SLACKPKGPLUS_$PREPO/#" >> ${TMPDIR}/CHECKSUMS.md5
fi
else
egrep -e ^[a-f0-9]{32} ${TMPDIR}/CHECKSUMS.md5-$PREPO|egrep -v -- "-(x86_64|arm)-" |sed -r "s# \./# ./SLACKPKGPLUS_$PREPO/#" >> ${TMPDIR}/CHECKSUMS.md5
fi
@ -601,7 +603,6 @@ if [ "$SLACKPKGPLUS" = "on" ];then
local MSGLIST=""
local USERKEY
find /var/log/packages/ -type f -printf "%f\n" | sort > ${TMPDIR}/installed.tmp
# -- Get the basename of packages which have been effectively
@ -678,7 +679,7 @@ if [ "$SLACKPKGPLUS" = "on" ];then
ls -1 /var/log/packages > $TMPDIR/tmplist
for i in $SHOWLIST; do
PKGFOUND=$(grep -m1 -e "^$(echo $i|rev|cut -f4- -d-|rev)-[^-]\+-[^-]\+-[^-]\+$" $TMPDIR/tmplist)
PKGFOUND=$(grep -m1 -e "^$(echo $i|rev|cut -f4- -d-|rev)-[^-]\+-[^-]\+-[^-]\+$" $TMPDIR/tmplist)
REPOPOS=$(grep -m1 " $(echo $i|sed 's/\.t.z//') " $TMPDIR/pkglist|awk '{print $1}'|sed 's/SLACKPKGPLUS_//')
getpkg $i upgradepkg Upgrading
if [ -e "/var/log/packages/$(echo $i|sed 's/\.t.z//')" ];then
@ -703,7 +704,7 @@ if [ "$SLACKPKGPLUS" = "on" ];then
DELALL="$OLDDEL"
fi
for i in $SHOWLIST; do
INSTALL_T='installed: '
INSTALL_T='installed: '
if [ -e /var/log/packages/$(echo $i|sed 's/\.t.z//') ];then
INSTALL_T='reinstalled:'
fi
@ -747,8 +748,8 @@ if [ "$SLACKPKGPLUS" = "on" ];then
done
if [[ "$CMD" == "upgrade" || "$CMD" == "upgrade-all" ]] && [ "$ALLOW32BIT" == "on" ] ; then
ARCH="\($ARCH\)\|\([i]*[3456x]86[^_]*\)"
echo -e "i[3456]86\nx86" > $TMPDIR/greylist.32bit
ARCH="\($ARCH\)\|\([i]*[3456x]86[^_]*\)"
echo -e "i[3456]86\nx86" > $TMPDIR/greylist.32bit
fi
if [ "$CMD" == "install" ] || [ "$CMD" == "upgrade" ] || [ "$CMD" == "reinstall" ] || [ "$CMD" == "remove" ] ; then

View file

@ -7,17 +7,21 @@ SLACKPKGPLUS=on
# set to '2' to show always show the download bar
VERBOSE=1
# Add custom option to 'wget'
#WGETOPTS="--timeout=5 --tries=1"
# Enable (on) / Disable (off) notification events (see notifymsg.conf)
#ENABLENOTIFY=off
# Enable (1) / Disable (0) the official slackpkg blacklist. May be useful to temporarily skip
# the slackware blacklist. You can also override it from command line:
# 'USEBL=0 slackpkg upgrade-all'
USEBL=1
# Add custom option to 'wget'.
# You can solve the repository indisponibility issue by set a timeout here
WGETOPTS="--timeout=5 --tries=1"
# Enable (on) / Disable (off) notification events (see notifymsg.conf)
#ENABLENOTIFY=off
# Enable (on) / Disable (off) the greylist feature. See /etc/slackpkg/greylist
GREYLIST=on
# If two or more repositories contains some same packages, you can specify
# from which repository you prefer to search it.
# The syntax is "<repository_name>:<package_name>"
@ -28,10 +32,9 @@ USEBL=1
#PKGS_PRIORITY=( myrepo:.* )
#
# List repositories you want to use (defined below).
# List repositories you want to use (defined below)
# remember to launch 'slackpkg update' if you modify that row.
REPOPLUS=( slackpkgplusdev restricted alienbob slacky )
REPOPLUS=( slackpkgplus restricted alienbob slacky )
# Define mirrors (uncomment one or more mirror; remember to add it to REPOPLUS)
@ -44,7 +47,7 @@ MIRRORPLUS['restricted']=http://taper.alienbase.nl/mirrors/people/alien/restrict
MIRRORPLUS['slacky']=http://repository.slacky.eu/slackware-14.1/
# use this to keep the slackpkg+ package updated
MIRRORPLUS['slackpkgplusdev']=http://slakfinder.org/slackpkg+dev/
MIRRORPLUS['slackpkgplus']=http://slakfinder.org/slackpkg+/
# Local repository:
#MIRRORPLUS['alienbob']=file://repositories/alien/sbrepos/14.1/x86/

View file

@ -12,19 +12,23 @@ VERBOSE=1
# installation (possibly unsafe). Please, do not install both 32 and 64bit of the same
# package to avoid problems, and NEVER upgrade exitant 64bit packages with relative 32bit package.
# Do not forget to install the multilibs.
#ALLOW32BIT=off
# Add custom option to 'wget'
#WGETOPTS="--timeout=5 --tries=1"
# Enable (on) / Disable (off) notification events (see notifymsg.conf)
#ENABLENOTIFY=off
ALLOW32BIT=off
# Enable (1) / Disable (0) the official slackpkg blacklist. May be useful to temporarily skip
# the slackware blacklist. You can also override it from command line:
# 'USEBL=0 slackpkg upgrade-all'
USEBL=1
# Add custom option to 'wget'.
# You can solve the repository indisponibility issue by set a timeout here
WGETOPTS="--timeout=5 --tries=1"
# Enable (on) / Disable (off) notification events (see notifymsg.conf)
#ENABLENOTIFY=off
# Enable (on) / Disable (off) the greylist feature. See /etc/slackpkg/greylist
GREYLIST=on
# If two or more repositories contains some same packages, you can specify
# from which repository you prefer to search it.
# The syntax is "<repository_name>:<package_name>"
@ -37,10 +41,11 @@ USEBL=1
# If you want a multilib system, uncomment the multilib repository and set:
#PKGS_PRIORITY=( multilib:.* )
#
# (Use /usr/doc/slackpkg+-*/setupmultilib.sh to setup a multilib configuration)
# List repositories you want to use (defined below)
# remember to launch 'slackpkg update' if you modify that row.
REPOPLUS=( slackpkgplusdev restricted alienbob slacky )
REPOPLUS=( slackpkgplus restricted alienbob slacky )
# Define mirrors (uncomment one or more mirror; remember to add it to REPOPLUS)
@ -54,7 +59,7 @@ MIRRORPLUS['restricted']=http://taper.alienbase.nl/mirrors/people/alien/restrict
MIRRORPLUS['slacky']=http://repository.slacky.eu/slackware64-14.1/
# use this to keep the slackpkg+ package updated
MIRRORPLUS['slackpkgplusdev']=http://slakfinder.org/slackpkg+dev/
MIRRORPLUS['slackpkgplus']=http://slakfinder.org/slackpkg+/
# Slackware current - x86_64
#MIRRORPLUS['multilib']=http://taper.alienbase.nl/mirrors/people/alien/multilib/current/
@ -67,6 +72,7 @@ MIRRORPLUS['slackpkgplusdev']=http://slakfinder.org/slackpkg+dev/
#MIRRORPLUS['myrepo']=dir://repositories/mypackages/
#
# Supported Repositories (see /usr/doc/slackpkg+-* for details):
#

View file

@ -20,17 +20,20 @@ if [ "$SLACKPKGPLUS" = "on" ];then
ONOFF=on
fi
cat $TMPDIR/greylist.* >$TMPDIR/greylist
if [ "$GREYLIST" == "off" ];then
>$TMPDIR/greylist
fi
grep -Ew -f $TMPDIR/greylist $TMPDIR/pkglist|awk '{print $2}' >$TMPDIR/unchecklist
rm -f $TMPDIR/dialog.tmp
if [ "$2" = "upgrade" ]; then
ls -1 /var/log/packages > $TMPDIR/tmplist
for i in $1; do
TMPONOFF=$ONOFF
TMPONOFF=$ONOFF
BASENAME=$(cutpkg $i)
PKGFOUND=$(grep -m1 -e "^${BASENAME}-[^-]\+-\(noarch\|fw\|${ARCH}\)" $TMPDIR/tmplist)
REPOPOS=$(grep -m1 " $(echo $i|sed 's/\.t.z//') " $TMPDIR/pkglist|awk '{print $1}'|sed 's/SLACKPKGPLUS_//')
grep -q "^$(echo $i|rev|cut -f4- -d-|rev)$" $TMPDIR/unchecklist && TMPONOFF="off"
echo "$i \"$REPOPOS\" $TMPONOFF \"currently installed: $PKGFOUND\"" >>$TMPDIR/dialog.tmp
done