summaryrefslogtreecommitdiffstats
path: root/abs/core-testing/linhes-scripts/linhes_update3.sh
blob: 5dc0b4da870e12439e1a2b08058b43af14c7c0d4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/bin/bash
sudo killall osd_cat
cat /tmp/to_be_upgraded | sed 's/ /\n/g' | sed '/^$/d' | grep - > /tmp/to_be_upgraded2
COUNT=$(wc -l /tmp/to_be_upgraded2 | awk '{print $1}')
if [ $COUNT -lt 20 ]
	then
	cat /tmp/to_be_upgraded2 | osd_cat -p top -f"-adobe-courier-bold-*-*-*-34-*-*-*-*-*" -d 12 -A centre -l 20
	else
	cat /tmp/to_be_upgraded2 | osd_cat -p top -f"-adobe-courier-bold-*-*-*-34-*-*-*-*-*" -d 1 -A centre -l 20 -w
fi
if grep kernel26 /tmp/to_be_upgraded2
then
	killall -9 osd_cat
	echo -e "Please note:\The kernel will be upgraded.\nThis will require a reboot.\nPlease do so when no jobs are running." | osd_cat -p middle -s 5 -f"-adobe-courier-bould-*-*-*-34-*-*-*-*-*" -d 10 -A centre
else
	exit
fi