#!/bin/bash export TEXTDOMAIN="zero-lliurex-java" zero-center add-pulsating-color zero-lliurex-java rc=0 TIEMPO=120 AUX=0 sudo gnome-terminal -e "/usr/share/zero-lliurex-java-data/jre-1_5_0_22-linux-i586.bin" --working-directory="/usr/lib/jvm/" while [ ! -e "/usr/lib/jvm/jre1.5.0_22/bin/javaws" ] ; do sleep 1 let AUX=AUX+1 echo "Tiempo pasado fue mejor $AUX" if [ $AUX -eq $TIEMPO ] ; then zenity --error --text="Su tiempo ha expirado..." exit 1 fi done if [ ! -L /etc/alternatives/mozilla-javaplugin.so ] ; then sudo ln -s /usr/lib/jvm/java-6-sun/jre/lib/i386/libnpjp2.so /etc/alternatives/mozilla-javaplugin.so fi if [ ! -L /usr/lib/mozilla/plugins/libjavaplugin.so ] ; then sudo ln -s /etc/alternatives/mozilla-javaplugin.so /usr/lib/mozilla/plugins/libjavaplugin.so fi update-alternatives --install "/usr/bin/javaws" "javaws" "/usr/lib/jvm/jre1.5.0_22/bin/javaws" 1500|| rc=1 if [ $rc -eq 0 ] ; then zenity --info --text="Installation completed" zero-center remove-pulsating-color zero-lliurex-java zero-center set-configured java fi exit 0