Skip to content
Snippets Groups Projects
Commit b42394a6 authored by Diego Giovane Pasqualin's avatar Diego Giovane Pasqualin
Browse files

le-proinfodata: Don't show dialog if INEP was already configured

parent 53105982
Branches
No related tags found
No related merge requests found
Package: le-proinfodata Package: le-proinfodata
Version: 1.2.37 Version: 1.2.38
Maintainer: <proinfodata@c3sl.ufpr.br> Maintainer: <proinfodata@c3sl.ufpr.br>
Architecture: i386 Architecture: i386
Section: main Section: main
......
...@@ -137,10 +137,21 @@ function verify_proxy() { ...@@ -137,10 +137,21 @@ function verify_proxy() {
return 0 return 0
} }
### MAIN #######################################################################
# Check whether the INEP code is already set and exit
if [[ -f "$F_INEP" ]]; then
exit 0
fi
zenity --info --height=100 --no-wrap --title="INEP" --text="O agente de acompanhamento do projeto PROINFODATA foi instalado nesta máquina.\nPara torná-lo funcional, entretanto, é necessário fornecer informações sobre as configurações de proxy,\nalém do número INEP da instituição.\nPara saber mais sobre o projeto, visite o site http://seed.c3sl.ufpr.br." zenity --info --height=100 --no-wrap --title="INEP" --text="O agente de acompanhamento do projeto PROINFODATA foi instalado nesta máquina.\nPara torná-lo funcional, entretanto, é necessário fornecer informações sobre as configurações de proxy,\nalém do número INEP da instituição.\nPara saber mais sobre o projeto, visite o site http://seed.c3sl.ufpr.br."
VALID=false VALID=false
while [[ $VALID = "false" ]]; do while [[ $VALID = "false" ]]; do
INEP=$(zenity --entry --title="INEP" --text="Digite seu INEP ou a mensagem: $TEXT" --cancel-label="Cancelar" --width=600 --height=100) INEP=$(zenity --entry --title="INEP" --text="Digite seu INEP ou a mensagem: $TEXT" --cancel-label="Cancelar" --width=600 --height=100)
# The user cannot simply cancel the operation
if [[ $? -ne 0 ]]; then
continue
fi
#Check strings #Check strings
INEP_C=$(echo $INEP|tr -d " "|tr '[[:upper:]]' '[[:lower:]]') INEP_C=$(echo $INEP|tr -d " "|tr '[[:upper:]]' '[[:lower:]]')
TEXT_C=$(echo $TEXT|tr -d " "|tr -d "\""| tr '[[:upper:]]' '[[:lower:]]') TEXT_C=$(echo $TEXT|tr -d " "|tr -d "\""| tr '[[:upper:]]' '[[:lower:]]')
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment