Skip to content

Commit ad9671d

Browse files
committed
修复BUG:兼容Linux版IDEA
1 parent f984383 commit ad9671d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/main/java/com/sjhy/plugin/ui/SelectSavePath.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -287,9 +287,11 @@ private void refreshPath() {
287287
String packageName = packageField.getText();
288288
// 获取基本路径
289289
String path = getBasePath();
290+
// 兼容Linux路径
291+
path = path.replaceAll("\\\\", "/");
290292
// 如果存在包路径,添加包路径
291293
if (!StringUtils.isEmpty(packageName)) {
292-
path += "\\" + packageName.replaceAll("\\.", "\\\\");
294+
path += "/" + packageName.replaceAll("\\.", "/");
293295
}
294296
pathField.setText(path);
295297
}

0 commit comments

Comments
 (0)