swiftbar / SwiftBar

Powerful macOS menu bar customization tool
https://swiftbar.app
MIT License
2.93k stars 92 forks source link

Swiftbar terminats after Upgrade to 1.4.3 #304

Closed warmup72 closed 2 years ago

warmup72 commented 2 years ago

I´m Using the newest swiftbar on my MBP macos 12.3. After the upgrade to swiftbar 1.4.3 the app terminates suddenly. The console shows:

2022-03-27 14:31:51.933+0200 -- SwiftBar (SwiftBar) -- Failed to execute script /Users/test/Applications/SwiftBar/fb70d255b8be71efe274.tmp

Nothing changed since 1.4.2 in my scripts. Can someone explain, what went wrong?

melonamin commented 2 years ago

Looks like your Plugin Folder set to ~/Applications/Swiftbar.

Can you show the output of defaults read com.ameba.SwiftBar?

warmup72 commented 2 years ago

Yes, thats right! The Output: { DisabledPlugins = ( ); MakePluginExecutable = 1; NSNavLastRootDirectory = "~"; NSNavPanelExpandedSizeForOpenMode = "{800, 448}"; "NSStatusItem Preferred Position SparseBar.5m.sh" = 413; "NSStatusItem Preferred Position myStartBar.5m.sh" = 377; "NSStatusItem Visible Item-0" = 0; "NSStatusItem Visible Item-1" = 0; "NSStatusItem Visible Item-2" = 0; "NSStatusItem Visible Item-3" = 0; "NSStatusItem Visible Item-4" = 0; "NSStatusItem Visible SparseBar.5m.sh" = 1; "NSStatusItem Visible myStartBar.5m.sh" = 1; "NSWindow Frame NSNavPanelAutosaveName" = "496 485 800 448 0 0 1792 1095 "; "NSWindow Frame com.sindresorhus.Preferences.FrameAutosaveName" = "691 262 750 428 0 0 1792 1095 "; PluginDirectory = "/Users/test/Applications/SwiftBar"; SUEnableAutomaticChecks = 0; SUHasLaunchedBefore = 1; SUSendProfileInfo = 0; }

melonamin commented 2 years ago

Ok, then do this to fix it(replace the path): defaults write com.ameba.SwiftBar PluginDirectory "/Users/alex/Documents/SwiftBar/#261"

Not sure why it happened to you! 🤷‍♂️

warmup72 commented 2 years ago

Good evening, I'm not sure if I understand this correctly. I have set the plugin /Users/test/Applications/SwiftBar directory. Why should I change it to a user I don't have?

melonamin commented 2 years ago

Ok, my bad, on my machine /Application is linked to /Users/user/Applications/ and I forgot that this is not the default. I thought that you've accedentely set the plugin folder to SwiftBar app path, which apparantly is not the case.

Back to your original question:

2022-03-27 14:31:51.933+0200 -- SwiftBar (SwiftBar) -- Failed to execute script /Users/test/Applications/SwiftBar/fb70d255b8be71efe274.tmp

SwiftBar tries to execute every file in the plugin folder, do you have this file in there? Do you need it?

warmup72 commented 2 years ago

Yes, now it is clear. Strange that it happens after upgrading to 1.4.3 of all places. I mistakenly write a tmp file in this directory. Funny. The script has been running for a few years now and, of all things, after the upgrade 3x in 4 days. Thanks for the quick help and sorry for the stupid question