summaryrefslogtreecommitdiffstats
path: root/root
diff options
context:
space:
mode:
authorAnton Luka Šijanec <anton@sijanec.eu>2024-03-19 21:22:34 +0100
committerAnton Luka Šijanec <anton@sijanec.eu>2024-03-19 21:22:34 +0100
commitd1dc48a69521c8c6b91563c0efb9b81120b07e84 (patch)
treea899bd6c9b905b06a39f0e1eeeaa97031dbb0469 /root
parentb (diff)
downloadn-d1dc48a69521c8c6b91563c0efb9b81120b07e84.tar
n-d1dc48a69521c8c6b91563c0efb9b81120b07e84.tar.gz
n-d1dc48a69521c8c6b91563c0efb9b81120b07e84.tar.bz2
n-d1dc48a69521c8c6b91563c0efb9b81120b07e84.tar.lz
n-d1dc48a69521c8c6b91563c0efb9b81120b07e84.tar.xz
n-d1dc48a69521c8c6b91563c0efb9b81120b07e84.tar.zst
n-d1dc48a69521c8c6b91563c0efb9b81120b07e84.zip
Diffstat (limited to 'root')
-rwxr-xr-xroot/posodobi.sh5
1 files changed, 3 insertions, 2 deletions
diff --git a/root/posodobi.sh b/root/posodobi.sh
index a48a7d4..c150fb5 100755
--- a/root/posodobi.sh
+++ b/root/posodobi.sh
@@ -10,11 +10,12 @@ then
echo začasne datoteke ni uspelo izdelati. mktemp je končal s $status.
exit 1
fi
+ set -o pipefail
$0 --no-ask --colour 2>&1 | aha --black --title "`hostname` $0 cron `date`" > $t
status=$?
if [ ! $status -eq 0 ]
then
- echo posodobitev ni uspela. $0 je končal s $status. izhod je dostopen na http://`hostname`.sijanec.eu/$t
+ echo posodobitev ni uspela. $0 je končal s $status. izhod je dostopen na http://tmp.sijanec.eu/`rev <<<$t | cut -d/ -f1 | rev`
fi
chmod go+r $t
exit $status
@@ -24,7 +25,7 @@ f=
a=
grep "no-sync" <<<"$@" || /usr/sbin/emaint sync --auto
grep "no-ask" <<<"$@" || a=--ask
-grep "colo" <<<"$@" || f="$f --color y"
+grep "colo" <<<"$@" && f="$f --color y"
[ `hostname` = varovalka ] && f="$f --exclude=media-libs/mesa"
emerge --tree --verbose --update $f $a --newuse --changed-use --backtrack 30 --deep --with-bdeps=y --rebuilt-binaries --autounmask --autounmask-write --autounmask-backtrack=y @world
emerge --verbose $f --autounmask-write --autounmask @preserved-rebuild