From 40d5e0e6037b737f5ab7b3dfe6d2a6fd83e1d644 Mon Sep 17 00:00:00 2001 From: zhangqian <2323020057@qq.com> Date: Thu, 4 Jun 2026 14:32:11 +0800 Subject: [PATCH] 1 --- .../modules/file/start/controller/BitFunController.java | 9 ++++----- src/main/resources/application.yml | 6 +++--- 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/src/main/java/com/oneflow/studio/modules/file/start/controller/BitFunController.java b/src/main/java/com/oneflow/studio/modules/file/start/controller/BitFunController.java index 6474f0d..20168fb 100644 --- a/src/main/java/com/oneflow/studio/modules/file/start/controller/BitFunController.java +++ b/src/main/java/com/oneflow/studio/modules/file/start/controller/BitFunController.java @@ -26,13 +26,12 @@ public class BitFunController { @PostMapping("/open") public Map 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) { @@ -90,4 +89,4 @@ public class BitFunController { } return value.replaceAll("[\\\\/:*?\"<>|]", "-").trim(); } -} \ No newline at end of file +} diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml index b7f8d19..635962d 100644 --- a/src/main/resources/application.yml +++ b/src/main/resources/application.yml @@ -2,6 +2,6 @@ server: port: 8089 bitfun: - workspace-root: D:\workpsace-temp - install-dir: D:\bitfun - exe-path: D:\bitfun\bitfun-desktop.exe \ No newline at end of file + workspace-root: E:\workspace-template + install-dir: E:\workSpace\soft-temp\BitFun + exe-path: E:\workSpace\soft-temp\BitFun\bitfun-desktop.exe \ No newline at end of file