linux-tutorial/codes/linux/ops/soft/main.sh

31 lines
1.0 KiB
Bash
Raw Normal View History

2019-03-04 20:41:51 +08:00
#!/usr/bin/env bash
cat << EOF
***********************************************************************************
2019-05-07 11:39:42 +08:00
* 欢迎使用 Linux CentOS 软件安装配置脚本
2019-03-04 20:41:51 +08:00
* Author: Zhang Peng
***********************************************************************************
EOF
2019-05-07 11:39:42 +08:00
path=$(cd "$(dirname "$0")"; pwd)
2019-03-04 20:41:51 +08:00
PS3="Please select script type: "
2019-05-07 12:10:12 +08:00
select item in "git" "jdk" "maven" "nodejs" "redis"
2019-03-04 20:41:51 +08:00
do
path=$(cd "$(dirname "$0")"; pwd)
case ${item} in
"git") yum install -y git ;;
2019-05-07 14:14:30 +08:00
"jdk") curl -o- https://raw.githubusercontent.com/dunwu/os-tutorial/master/codes/linux/ops/soft/jdk8-install.sh | bash ;;
2019-05-07 11:39:42 +08:00
"maven") wget -qO- https://raw.githubusercontent.com/dunwu/os-tutorial/master/codes/linux/ops/soft/maven-install.sh | bash ;;
2019-05-07 12:07:59 +08:00
"nodejs") curl -o- https://raw.githubusercontent.com/dunwu/os-tutorial/master/codes/linux/ops/soft/nodejs-install.sh | bash ;;
2019-05-07 14:14:30 +08:00
"redis") curl -o- https://raw.githubusercontent.com/dunwu/os-tutorial/master/codes/linux/ops/soft/redis-install.sh | bash ;;
2019-03-04 20:41:51 +08:00
*)
echo -e "输入项不支持!"
main
;;
esac
break
done