local check bug fix

This commit is contained in:
jiangzhongxiang 2019-08-12 16:17:43 +08:00
parent 6ac54237ae
commit 60800f68f3
3 changed files with 18 additions and 2 deletions

View File

@ -346,7 +346,7 @@ public class GameController {
//先检查在本地是否存在
String tpiWorkspace = TpUtils.buildTpiWorkspace(appConfig.getWorkspace(), tpiID);
LocalCheck localCheck = new LocalCheck(tpiID, tpiWorkspace, tpiGitURL);
LocalCheck localCheck = new LocalCheck(tpiID, tpiGitURL, tpiWorkspace);
LocalCheckJob LocalCheckJob = BeanFactory.getObejct(LocalCheckJob.class);
LocalCheckJob.setLocalCheck(localCheck);
gitCloneTaskExecutor.execute(LocalCheckJob);

View File

@ -30,7 +30,7 @@ public class LocalCheckJob implements Runnable {
String tpiGitUrl = localCheck.getTpiGitURL();
try {
String tpiWorkspace = localCheck.getTpiWorkSpace();
String tpiRepoName = GameHelper.getRepoName(localCheck.getTpiGitURL());
String tpiRepoName = GameHelper.getRepoName(tpiGitUrl);
String tpiRepoPath = TpUtils.buildTpiRepoPath(tpiWorkspace, tpiRepoName);
if (new File(tpiRepoPath).exists()) {
return; // 存在直接返回

View File

@ -0,0 +1,16 @@
package com.educoder.bridge.common.utils;
import org.junit.Test;
public class GameHelperTest {
@Test
public void test() {
String url = "http://172.16.94.154:9000/innov/zutv35pnqi20190720180217.git";
String repName = GameHelper.getRepoName(url);
System.out.println(repName);
}
}