Advertisement
Guest User

Untitled

a guest
Jun 27th, 2017
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 1.13 KB | None | 0 0
  1. #!/bin/sh
  2. #Affichage de la vue
  3.  
  4. tmp=/tmp/choix$$
  5. dialog  --backtitle "Date et Heure" \
  6.         --title "Config-O-Matic" \
  7.         --msgbox "Nicolas GERON\nPierre SIGWALT\nGroupe B\n\n Press <Enter> to continue..." 10 45 \
  8. secu1=1
  9.  
  10. while [ $secu1=1 ]
  11. do
  12. dialog --menu "menu" 20 20 20 1 Machine 2 Reseau 3 Systeme 4 Menu 5 Quitter 2>$tmp \
  13.         choix=$(cat $tmp);
  14.         if  [ $choix=1 ]; then
  15.                 echo $choix
  16.                 dialog --msgbox "Catégorie Machine. " 10 45
  17.                        --clear
  18.         elif [ $choix=2 ]; then
  19.                 dialog --msgbox "Catégorie Reseau. " 10 45
  20.                        --clear
  21.         elif [ $choix=3 ]; then
  22.  
  23.                 dialog --msgbox "Catégorie Systeme. " 10 45
  24.                        --clear
  25.         elif [ $choix=4 ]; then
  26.                 dialog --msgbox "Revenir au menu principal " 10 45
  27.                        --clear
  28.                 secu1=0
  29.                 break
  30.         elif [ $choix=5 ]; then
  31.                 dialog --msgbox "Quitter le programme" 10 45
  32.                        --clear
  33.          else
  34.            echo "not a choix"
  35.         fi
  36. done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement