Outils pour utilisateurs

Outils du site


bash:start

Différences

Ci-dessous, les différences entre deux révisions de la page.

Lien vers cette vue comparative

Prochaine révision
Révision précédente
bash:start [2020/08/27 16:05] – créée jonathanbash:start [2020/08/27 16:10] (Version actuelle) jonathan
Ligne 2: Ligne 2:
  
 <code> <code>
-read -p 'Magic question ? (y/n) ' -r magicVar+read -p 'Magic question ? (y/N) ' -r magicVar
 if [[ "$magicVar" =~ ^([yY][eE][sS]|[yY]|[oO][uU][iI]|[oO])$ ]] if [[ "$magicVar" =~ ^([yY][eE][sS]|[yY]|[oO][uU][iI]|[oO])$ ]]
 then then
Ligne 10: Ligne 10:
   echo 'At your command...'   echo 'At your command...'
   exit 42   exit 42
 +else
 +  echo 'What is that ?'
 +  sleep 1
 +  echo "Baby don't hurt me"
 +  sleep 1
 +  echo "Don't hurt me"
 +  sleep 1
 +  echo "No more..."
 +  exit 43
 fi fi
 </code> </code>
bash/start.1598537116.txt.gz · Dernière modification : de jonathan