#!/bin/sh TOKEN=0 PACKAGE_LIST="/usr/share/lliurex-zero-installers/zero-salt-files" THISPACKAGE="Salt" export TEXTDOMAIN="lliurex-zero-installer-generic" ERROR_TEXT1="$(gettext 'The package')" ERROR_TEXT2="$(gettext 'has not been installed.\nCheck if mirror was created or your sources.list is update today.')" ERROR_TEXT="$ERROR_TEXT1 $THISPACKAGE $ERROR_TEXT2" for x in $(cat $PACKAGE_LIST | sed -e "s%^\([[:graph:]]\+\).*%\1%g" | tr "\n" " "); do a=$(apt-cache search $x) if [ -z "$a" ]; then TOKEN=0 break fi done if [ $TOKEN -eq 1 ]; then zenity --error --text="$ERROR_TEXT" exit 0 fi apt-get update synaptic --hide-main-window --non-interactive --set-selections-file $PACKAGE_LIST chown -R $USER:$GROUPS $HOME/.config/libreoffice/ zenity --info --text="Tot ha anat bé, cal reiniciar l'ordinador." zero-sqlmanager -s zero-salt 1 exit 0