今天是WEBSOCKET,,
先完成一个SHELL的GETOPS,周一就用得着。
#!/bin/bash echo "usage: ./$0 -t (prism|opscripts)" function scp_prism() { echo "scp_prism()" } function scp_opscripts() { echo "scp_opscripts()" } while getopts t:h OPT do case $OPT in "t") TYPE=$OPTARG if [ $TYPE = "prism" ];then scp_prism fi if [ $TYPE = "opscripts" ];then scp_opscripts fi ;; "h") echo "./$0 -t (prism|opscripts)" ;; \?) echo "$0 -t (prism|opscripts)" exit -1 esac done
时间: 2024-10-12 13:14:25