This commit is contained in:
emdee 2024-01-09 15:39:19 +00:00
parent 6b4fca0353
commit ddb600ead2
34 changed files with 770 additions and 343 deletions

View file

@ -3,6 +3,7 @@
prog=$( basename $0 .bash )
ROLE=base
PYVER=3
LOG_DIR=/usr/local/var/logs/portage
[ -d $LOG_DIR ] || mkdir -p $LOG_DIR
@ -37,15 +38,16 @@ LARGS="$LARGS --noreplace"
# LARGS="$LARGS --exclude "
LOG=$LOG_DIR/$LOG
export PYTHONPATH=
echo INFO: $LARGS $ARGS >> $LOG 2>&1
nice python$BASE_PYTHON3_MINOR $( which emerge ) $LARGS $ARGS >> $LOG 2>&1
[ $? -ne 0 ] && exit $?
echo INFO: emerge $LARGS $ARGS |tee -a $LOG >&2
nice python$PYVER $( which emerge ) $LARGS $ARGS >> $LOG 2>&1
retval=$?
[ $retval -ne 0 ] && echo ERROR: $retval $LOG && tail $LOG && exit $retval
if grep ImportError $LOG ; then
echo ERROR: ImportError $ARGS && exit 10
echo ERROR: ImportError $LOG && exit 10
elif grep ParseError $LOG ; then
echo ERROR: ParseError $ARGS && exit 11
echo ERROR: ParseError $LOG && exit 11
elif grep 'Your current profile is invalid' $LOG ; then
echo ERROR: Your current profile is invalid $ARGS && exit 12
echo ERROR: Your current profile is invalid $LOG && exit 12
fi
exit 0

View file

@ -27,7 +27,7 @@ gpg2 --verify --keyring $keyf $BASE_PORTDIR/Manifest >/tmp/K$$.log 2>&1 || exit
grep 'using RSA key' /tmp/K$$.log || exit 4
grep 'Primary key fingerprint:' /tmp/K$$.log | sed -e 's/.*: //' -e 's/ //g' > /tmp/K$$.key || exit 5
if route | grep -q ^default ; then
if grep -q "^wlan[1-9][ ]00000000" /proc/net/route ; then
. /root/bin/tor.sh
wget -O /tmp/K$$.html https://www.gentoo.org/downloads/signatures/ || exit 0
grep "`cat /tmp/K$$.key`" /tmp/K$$.html || {