Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Configs/Base.xcconfig
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
MARKETING_VERSION = 0.1.2
MARKETING_VERSION = 0.1.3
CURRENT_PROJECT_VERSION = 0
DEBUG_MODE = NO
5 changes: 5 additions & 0 deletions PCL.Mac/App/AppDelegate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,11 @@ class AppDelegate: NSObject, NSApplicationDelegate {
try SwiftScaffolding.Logger.enableLogging(url: URLConstants.logsDirectoryURL.appending(path: "swift-scaffolding.log"))
}
_ = LauncherConfig.shared
executeTask("清理临时文件") {
for url in try FileManager.default.contentsOfDirectory(at: URLConstants.tempURL, includingPropertiesForKeys: nil) {
try FileManager.default.removeItem(at: url)
}
}
executeTask("加载版本缓存") {
try VersionCache.load()
}
Expand Down
2 changes: 1 addition & 1 deletion PCL.Mac/ContentView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ private struct ExtraButtonsOverlay: View {
Image(imageName)
.resizable()
.scaledToFit()
.padding(12)
.padding(10)
.foregroundStyle(Color.color8)
}
.gesture(
Expand Down
2 changes: 2 additions & 0 deletions PCL.Mac/Managers/MinecraftLaunchManager.swift
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ class MinecraftLaunchManager: ObservableObject {
if ![0, 9, 15, 128 + 9, 128 + 15].contains(process.terminationStatus) {
log("游戏非正常退出")
self?.onGameCrash(instance: instance, options: launcher.options, logURL: launcher.logURL)
} else {
try? FileManager.default.removeItem(at: launcher.logURL)
}
DispatchQueue.main.async {
self?.cancel()
Expand Down