- Timestamp:
- 09/30/13 12:54:27 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/libIGCM/AA_RunChecker
r952 r953 45 45 # Get arguments from command line 46 46 # ------------------------------- 47 while [ $# -ne 0 ]; do48 case $ 1in49 -h|--help|-help)47 while getopts :hj:p:qsu: Opt ; do 48 case $Opt in 49 h) 50 50 echo "usage: $0 [-u user] [-q] [-j n] [-s] job_name" 51 51 echo " $0 [-u user] [-q] [-j n] -p config.card_path" 52 echo " $0 [-u user] [-q] [-j n] -r" 52 53 echo "" 53 54 echo "options :" … … 61 62 echo " the config.card instead of the job name." 62 63 exit 0 ;; 63 -j|-job-number) 64 NbHisto="$2" 65 shift 2 ;; 66 -p|-config-path) 67 ConfigPath="$2" 64 j) 65 NbHisto=${OPTARG} 66 ;; 67 p) 68 68 fg_path=true 69 shift 2 ;; 70 -q|-quiet) 69 ConfigPath=${OPTARG} 70 ;; 71 q) 71 72 fg_quiet=true 72 shift 1;;73 -s|-search)73 ;; 74 s) 74 75 fg_search=true 75 shift 1 ;; 76 -u|-user) 77 TargetUsr="$2" 78 shift 2 ;; 79 -*) 80 $0 -h 81 exit ;; 82 *) 83 break ;; 76 ;; 77 u) 78 TargetUsr=${OPTARG} 79 ;; 80 :) 81 echo "$0: -"${OPTARG}" option: missing value" 82 exit 1 83 ;; 84 \?) 85 echo "$0: -"${OPTARG}" option: not supported" 86 exit 1 87 ;; 84 88 esac 85 89 done 86 87 88 if ( ( ! ${fg_path} ) && [ $# -lt 1 ] ) ; then90 shift $(($OPTIND-1)) 91 92 if ( ( ! ${fg_path} ) && ( ! ${fg_running} ) && [ $# -lt 1 ] ) ; then 89 93 $0 -h 90 94 exit
Note: See TracChangeset
for help on using the changeset viewer.