Skip to content

Instantly share code, notes, and snippets.

View ricard33's full-sized avatar

Cédric RICARD ricard33

View GitHub Profile
@edouard-lopez
edouard-lopez / confirmation.bash
Created November 17, 2014 13:27
ask user for confirmation
#!/bin/bash
while true; do
read -p "$(printf "\tEditing…\t%s? [y/N]\n" )" yn;
case $yn in
[Yy]* )
echo "action_si_valide"
break;;
'') ;&
[Nn]*)