#!/bin/bash export TEXTDOMAIN="zero-lliurex-sketchup" MSG_NO_INTERNET=$(gettext "No Internet Connection has been detected. Please, check it") MSG_BAJAR=$(gettext "Google Sketchup will now be downloaded. Aprox. size 38,6MB") #Comprobar conexión a internet e instalar rc=0 host dl.google.com || rc=1 if [ $rc -eq 0 ] then zenity --info --text="$MSG_BAJAR" rc=0 host server.aula || rc=1 if [ $rc -eq 0 ] then HTTPPROXY=$http_proxy export http_proxy="proxy:3128" su $USER -c "wget -O /tmp/GoogleSketchUpWES.exe http://dl.google.com/sketchup/GoogleSketchUpWES.exe" export http_proxy=$HTTPPROXY else su $USER -c "wget -O /tmp/GoogleSketchUpWES.exe http://dl.google.com/sketchup/GoogleSketchUpWES.exe" fi su $USER -c "wine /tmp/GoogleSketchUpWES.exe" #Modificar una entrada del registro a 1, mediante el fichero /usr/share/google-sketchup/hw_ok_set.reg su $USER -c "regedit /usr/share/google-sketchup/hw_ok_set.reg" zero-sqlmanager -s zero-lliurex-sketchup 1 else zenity --error --text="$MSG_NO_INTERNET" fi exit 0