提交 a1967d82 编写于 作者: P prgrmz01@163.com

fix

上级 f54936b6
...@@ -12,9 +12,9 @@ echo "pwd:`pwd`; /usr/bin/git.original $new_args" >> /tmp/git.log ...@@ -12,9 +12,9 @@ echo "pwd:`pwd`; /usr/bin/git.original $new_args" >> /tmp/git.log
/usr/bin/git.original $new_args /usr/bin/git.original $new_args
#如果不含clone, 则处理完毕了 #如果不含clone, 则处理完毕了
cmdf=/tmp/`date +%s` pyf=/tmp/`date +%s`
echo python -c "'s=\"${new_args}\";print(\" clone \" in s) '" > $cmdf echo "s=\"${new_args}\";print(\" clone \" in s) " > $pyf
if [ "`sh -x $cmdf`" = "False" ] ; then if [ "`python $pyf`" = "False" ] ; then
echo "not clone cmd[${new_args}],done" >> /tmp/git.log echo "not clone cmd[${new_args}],done" >> /tmp/git.log
exit 0 exit 0
fi fi
...@@ -27,7 +27,7 @@ fi ...@@ -27,7 +27,7 @@ fi
git_dir_name=`python -c "s='$new_args'; s.replace(' ',' '); print(s.split(' ')[-1])" ` git_dir_name=`python -c "s='$new_args'; s.replace(' ',' '); print(s.split(' ')[-1])" `
git_dir="`pwd`/$git_dir_name" git_dir="`pwd`/$git_dir_name"
gitmodules_path=${git_dir}/.gitmodules gitmodules_path=${git_dir}/.gitmodules
test -cmdf ${gitmodules_path} && python /pubx/git-replace/replace_gitmodules_url.py ${gitmodules_path} test -pyf ${gitmodules_path} && python /pubx/git-replace/replace_gitmodules_url.py ${gitmodules_path}
echo ok >> /tmp/git.log #这句并不是废话, 是为了使得本脚本的退出值为正常0 echo ok >> /tmp/git.log #这句并不是废话, 是为了使得本脚本的退出值为正常0
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册