Skip to content

Commit

Permalink
# v1.0.2 新增CentOS6系统判断
Browse files Browse the repository at this point in the history
  • Loading branch information
Toyo authored Aug 24, 2017
1 parent 8c3fa88 commit bf065f0
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions aria2.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@ export PATH
#=================================================
# System Required: CentOS/Debian/Ubuntu
# Description: Aria2
# Version: 1.0.1
# Version: 1.0.2
# Author: Toyo
# Blog: https://doub.io/shell-jc4/
#=================================================
sh_ver="1.0.1"
sh_ver="1.0.2"
file="/root/.aria2"
aria2_conf="${file}/aria2.conf"
aria2_log="/root/.aria2/aria2.log"
Expand Down Expand Up @@ -73,6 +73,10 @@ Service_aria2(){
}
Installation_dependency(){
if [[ ${release} = "centos" ]]; then
cat /etc/redhat-release |grep 6\..*|grep -i centos>/dev/null
if [[ $? = 0 ]]; then
echo -e "${Error} CentOS6 系统不支持安装 Aria2(源没有Aria2包),请更换 CentOS7 或其他系统安装 !" && exit 1
fi
yum update
yum install aria2 curl unzip vim -y
elif [[ ${release} = "debian" ]]; then
Expand Down

0 comments on commit bf065f0

Please sign in to comment.