Saturday, July 29, 2017

▷ Case statement in shell script (case 문)

[ case statement sample in shell script ]


# ----------------------------------------------------- #
# ****************** Begin of Main ******************
# ----------------------------------------------------- #

   case "$1" in
   A) # To check A
      A_CHK
      ;;
   B) # To check B
      B_CHK
      ;;
   C) # To check C
      C_CHK
      ;;
   D) # To check D
      D_CHK
      ;;
   E) # To check E
      E_CHK
      ;;
   ALL)
      A_CHK
      B_CHK
      C_CHK
      D_CHK
      E_CHK
      ;;
   *)
      echo "usage: $0 A|B|C|D|E"
      exit 1
      ;;
   esac

No comments:

Post a Comment

◈ Recent Post

▷ UITest demo with TestOne (Mobile, Keypad and Drag until found tip)

[ UITest Demo Environment ] 1. UITest Solution: TestOne 2. Description 데모 설명    How to use keypad, and to drag until found.     키패드를...

◈ Popular Posts