diy支持任意仓库地址,修复添加ck报错,移除monk仓库内置

This commit is contained in:
whyour
2021-04-16 17:30:22 +08:00
parent 5de67b9679
commit 0563555a6a
7 changed files with 54 additions and 66 deletions
+6 -7
View File
@@ -11,8 +11,7 @@ ListCronCurrent=$ConfigDir/crontab.list
AuthConf=$ConfigDir/auth.json
declare -A BlackListDict
author=$1
repo=$2
url=$1
path=$3
blackword=$4
@@ -31,11 +30,11 @@ diyscriptsdir=/ql/diyscripts
mkdir -p ${diyscriptsdir}
if [ ! -d "$diyscriptsdir/${author}_${repo}" ]; then
echo -e "${author}本地仓库不存在,从gayhub拉取ing..."
url="https://ghproxy.com/https://github.com/${author}/${repo}"
if [ $author == "monk-coder" ] && [ $repo == "dust" ]; then
url="git@github.com:monk-coder/dust.git"
fi
echo -e "${author}本地仓库不存在,从远程拉取ing..."
repoTmp=${url##*/}
repo=${repoTmpName%.*}
tmp=${url%/*}
author=${tmp##*/}
cd ${diyscriptsdir} && git clone $url ${author}_${repo}
gitpullstatus=$?
[ $gitpullstatus -eq 0 ] && echo -e "${author}本地仓库拉取完毕"
+1
View File
@@ -12,6 +12,7 @@ echo -e "重新build...\n"
yarn install --network-timeout 1000000000 || yarn install --registry=https://registry.npm.taobao.org --network-timeout 1000000000
yarn build
yarn build-back
yarn cache clean
echo -e "重新build完成...\n"
echo -e "重启服务...\n"