git check 目录配置bugg fix

This commit is contained in:
jiangzhongxiang 2019-07-18 11:27:16 +08:00
parent 30d1c615fc
commit 15060583aa
1 changed files with 2 additions and 2 deletions

View File

@ -744,7 +744,7 @@ public class GameService {
// 第二个步骤检测远程版本库HEAD是否存在 .git/refs/heads/master没内容就是HEAD丢失了git branch
// 就会报错
command = commandBase + appConfig.getGitIP() + " 'cd repositories/"
command = commandBase + appConfig.getGitIP() + " 'cd " + appConfig.getGitRepoDir().trim() + "/"
+ identifier + "/" + tpiRepoName + ".git; git branch'";
result = ShellUtil.executeAndGetExitStatus(command);
if (result.getInteger("exitStatus") != 0) {
@ -753,7 +753,7 @@ public class GameService {
// /home/git/repositories/p79061248/klp26sqc.git/refs/tmp/;
// cd `ls -t | sed -n "2p"`; cat head >../../heads/master; git
// update-ref HEAD `cat head`'
command = commandBase + appConfig.getGitIP() + " 'cd repositories/"
command = commandBase + appConfig.getGitIP() + " 'cd " + appConfig.getGitRepoDir().trim() + "/"
+ identifier + "/" + tpiRepoName
+ ".git/refs/tmp; cd `ls -t | sed -n \"2p\"`; cat head >../../heads/master; git update-ref HEAD `cat head`'";
result = ShellUtil.executeAndGetExitStatus(command);