From c2b213a37c522111e6d9ce24df67b370a7b88ce8 Mon Sep 17 00:00:00 2001 From: whyour Date: Sat, 22 Jan 2022 21:57:02 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B5=8B=E8=AF=95=E5=9F=BA=E7=A1=80=E9=95=9C?= =?UTF-8?q?=E5=83=8Fnode=E7=89=88=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docker/Dockerfile | 2 +- shell/share.sh | 1 + shell/update.sh | 8 ++++---- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/docker/Dockerfile b/docker/Dockerfile index 8fe95376..385c4cc6 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -1,4 +1,4 @@ -FROM node:lts-alpine3.12 +FROM node:14.18.3-alpine3.12 ARG QL_MAINTAINER="whyour" LABEL maintainer="${QL_MAINTAINER}" ARG QL_URL=https://github.com/${QL_MAINTAINER}/qinglong.git diff --git a/shell/share.sh b/shell/share.sh index 00ca0cc0..797f77f7 100755 --- a/shell/share.sh +++ b/shell/share.sh @@ -69,6 +69,7 @@ import_config() { command_timeout_time=${CommandTimeoutTime:-"1h"} proxy_url=${ProxyUrl:-""} file_extensions=${RepoFileExtensions:-"js py"} + current_branch=${QL_BRANCH} if [[ -n "${DefaultCronRule}" ]]; then default_cron="${DefaultCronRule}" diff --git a/shell/update.sh b/shell/update.sh index 24244b80..89e42bb7 100755 --- a/shell/update.sh +++ b/shell/update.sh @@ -253,8 +253,8 @@ update_qinglong() { local no_restart="$1" [[ -f $dir_root/package.json ]] && ql_depend_old=$(cat $dir_root/package.json) - reset_romote_url ${dir_root} "https://github.com/whyour/qinglong.git" "master" - git_pull_scripts $dir_root "master" + reset_romote_url ${dir_root} "https://github.com/whyour/qinglong.git" ${current_branch} + git_pull_scripts $dir_root ${current_branch} if [[ $exit_status -eq 0 ]]; then echo -e "\n更新$dir_root成功...\n" @@ -270,8 +270,8 @@ update_qinglong() { local url="https://github.com/whyour/qinglong-static.git" if [[ -d ${ql_static_repo}/.git ]]; then - reset_romote_url ${ql_static_repo} ${url} "master" - git_pull_scripts ${ql_static_repo} "master" + reset_romote_url ${ql_static_repo} ${url} ${current_branch} + git_pull_scripts ${ql_static_repo} ${current_branch} else git_clone_scripts ${url} ${ql_static_repo} fi