Posted By

jlmarks on 03/30/14


Tagged

confirm Bash continue confirmation sure


Versions (?)

Bash confirmation


 / Published in: Bash
 

  1. read -p "do you want to continue?" -n 1 -r
  2. if [[ $REPLY =~ ^[Yy]$ ]]
  3. then
  4. #do whatever you are checking on
  5. fi

Report this snippet  

You need to login to post a comment.