wok-6.x annotate suggested-applications/stuff/default-app @ rev 18663
Up tazpkg(880); change pre- post-functions, etc. in random packages
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Fri Dec 04 02:45:17 2015 +0200 (2015-12-04) |
parents | 67404973a113 |
children |
rev | line source |
---|---|
jozee@5130 | 1 #!/bin/sh |
jozee@5130 | 2 |
jozee@5130 | 3 APP="$1" |
jozee@5130 | 4 |
jozee@5130 | 5 # Auto Install DEPENDS and/or SUGGESTED |
al@15186 | 6 install() { |
jozee@5130 | 7 TMPFILE="/tmp/installlist-$$" |
jozee@5130 | 8 #echo "pkgs to install: $1" |
jozee@5130 | 9 for pkg in $1 ; do |
al@15186 | 10 if [ ! -d /var/lib/tazpkg/installed/${pkg} ]; then |
jozee@5130 | 11 echo "$pkg" >> $TMPFILE |
al@15186 | 12 fi |
al@15186 | 13 done |
al@15186 | 14 |
jozee@5130 | 15 if [ -f $TMPFILE ] ; then |
jozee@5131 | 16 xterm -geometry 80x16 -title "Installing Packages (Press ENTER to close)" \ |
jozee@5131 | 17 -e "echo -e \"Installing packages as root. This option depends on \n `cat $TMPFILE`\" |
jozee@5131 | 18 subox \"tazpkg get-install-list $TMPFILE\" |
jozee@5131 | 19 echo -e \"----\nPress ENTER to close and to proceed further...\" |
jozee@5131 | 20 read i; exit 0; |
al@15186 | 21 " |
jozee@5130 | 22 rm -f $TMPFILE |
al@15186 | 23 fi |
jozee@5130 | 24 } |
jozee@5130 | 25 |
jozee@5130 | 26 if [ "$2" == "--install" ] ; then |
jozee@5130 | 27 SUGGESTED="$3" |
jozee@5130 | 28 install "$SUGGESTED" |
jozee@5130 | 29 fi |
jozee@5130 | 30 |
jozee@5130 | 31 $APP & |
jozee@5130 | 32 |
jozee@5130 | 33 exit 0 |