You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 lines
936 B

#!/bin/sh
# security upgrades
# /usr/bin/apt-get -q -y --ignore-hold --allow-change-held-packages --allow-unauthenticated -s dist-upgrade | /bin/grep ^Inst | /bin/grep -i securi | /usr/bin/cut -d\ -f2 | /bin/wc -w
# all upgrades
# /usr/bin/apt-get -q -y --ignore-hold --allow-change-held-packages --allow-unauthenticated -s dist-upgrade | /bin/grep ^Inst | /usr/bin/cut -d\ -f2 | /bin/wc -w
set -o noclobber
me="packs"
uppaks=$(/usr/bin/apt-get -q -y --ignore-hold --allow-change-held-packages --allow-unauthenticated -s dist-upgrade | /bin/grep ^Inst | /usr/bin/cut -d\ -f2 | /usr/bin/wc -w )
secpaks=$(/usr/bin/apt-get -q -y --ignore-hold --allow-change-held-packages --allow-unauthenticated -s dist-upgrade | /bin/grep ^Inst | /bin/grep -i securi | /usr/bin/cut -d\ -f2 | /usr/bin/wc -w )
LINE="packages,host="$myhost" packs="$uppaks"i, security="$secpaks"i "$(/bin/date -u +%s%N)$'\n'
writeline "$LINE" "$MAXLINES" "$me"