This commit is contained in:
parent
d44fed3744
commit
40d5e0e603
|
|
@ -26,13 +26,12 @@ public class BitFunController {
|
|||
|
||||
@PostMapping("/open")
|
||||
public Map<String, Object> open(@RequestBody BitFunReq request) throws Exception {
|
||||
System.out.println("开始测试--------------------------");
|
||||
System.out.println("正在打开BITFUN--------------------------");
|
||||
String projectName = safeName(request.getProjectName());
|
||||
String branch = safeName(request.getBranch());
|
||||
String codeName = safeName(request.getCodeName());
|
||||
|
||||
String workspaceName = codeName + projectName + "-" + branch;
|
||||
Path workspacePath = Paths.get(bitFunProperties.getWorkspaceRoot(), workspaceName);
|
||||
Path workspacePath = Paths.get(bitFunProperties.getWorkspaceRoot(), projectName, codeName, branch);
|
||||
|
||||
Files.createDirectories(workspacePath);
|
||||
|
||||
|
|
@ -54,7 +53,7 @@ public class BitFunController {
|
|||
|
||||
gitClone.directory(workspacePath.toFile());
|
||||
gitClone.inheritIO();
|
||||
|
||||
System.out.println("执行 Git 命令: git clone -b " + request.getBranch() + " " + request.getGitUrl() + " .");
|
||||
int cloneExitCode = gitClone.start().waitFor();
|
||||
|
||||
if (cloneExitCode != 0) {
|
||||
|
|
|
|||
|
|
@ -2,6 +2,6 @@ server:
|
|||
port: 8089
|
||||
|
||||
bitfun:
|
||||
workspace-root: D:\workpsace-temp
|
||||
install-dir: D:\bitfun
|
||||
exe-path: D:\bitfun\bitfun-desktop.exe
|
||||
workspace-root: E:\workspace-template
|
||||
install-dir: E:\workSpace\soft-temp\BitFun
|
||||
exe-path: E:\workSpace\soft-temp\BitFun\bitfun-desktop.exe
|
||||
Loading…
Reference in New Issue