Ghostty-per-Projekt-Builder: Template + make/rebuild-Skripte
- ghostty-template/Ghostty.app: lokal gebautes Ghostty v1.3.1 mit DockTilePlugin-Patch (eigenes Dock-Icon ueber Contents/Resources/DockIcon.png) - make-ghostty-app.sh: erzeugt pro Projekt eine App; Slots fuer icon/workdir/command/theme/bg/fg/font/font-size - rebuild-template.sh: baut Template lokal neu (nur Xcode, kein Zig/VM), gepinnt auf vendor/libghostty v1.3.1 - ghostty-template/dock-icon.patch: der DockTilePlugin-Patch - icons/robotunits.png - enthaelt zudem die vorausgehende MiniTerm/libghostty-Integration
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
diff --git a/macos/Sources/Features/Custom App Icon/DockTilePlugin.swift b/macos/Sources/Features/Custom App Icon/DockTilePlugin.swift
|
||||
index 990cd8b..6cf7031 100644
|
||||
--- a/macos/Sources/Features/Custom App Icon/DockTilePlugin.swift
|
||||
+++ b/macos/Sources/Features/Custom App Icon/DockTilePlugin.swift
|
||||
@@ -51,6 +51,15 @@ class DockTilePlugin: NSObject, NSDockTilePlugIn {
|
||||
return
|
||||
}
|
||||
|
||||
+ // Custom per-project dock icon: if the enclosing app bundle ships a
|
||||
+ // Resources/DockIcon.png, use it verbatim and skip the ghost logic.
|
||||
+ if let appURL = ghosttyAppURL,
|
||||
+ let img = NSImage(contentsOf: appURL.appendingPathComponent("Contents/Resources/DockIcon.png")) {
|
||||
+ dockTile.setIcon(img)
|
||||
+ iconChangeObserver = nil
|
||||
+ return
|
||||
+ }
|
||||
+
|
||||
// Try to restore the previous icon on launch.
|
||||
iconDidChange(ghosttyUserDefaults.appIcon, dockTile: dockTile)
|
||||
|
||||
Reference in New Issue
Block a user