diff --git a/plugins/gogs/hook/commit.tpl b/plugins/gogs/hook/commit.tpl index 3a0faf75b..d128983c0 100755 --- a/plugins/gogs/hook/commit.tpl +++ b/plugins/gogs/hook/commit.tpl @@ -7,10 +7,9 @@ GIT_USER_DIR="${GIT_SDIR}/{$USERNAME}" GIT_PROJECT_DIR="${GIT_USER_DIR}/{$PROJECT}" # echo $GIT_PROJECT_DIR -if [ ! -d $GIT_USER_DIR ];then +if [ ! -d $GIT_PROJECT_DIR ];then mkdir -p $GIT_USER_DIR && cd $GIT_USER_DIR - git clone $GIT_PROJECT_DIR - exit 0 + git clone $GITADDR fi unset GIT_DIR