Skip to content

Fix macosx ventura updater #768

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 13 commits into from
Feb 15, 2023
Merged
Changes from 1 commit
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
Prev Previous commit
Next Next commit
Added fallback restart for macosx.
  • Loading branch information
cmaglie committed Feb 15, 2023
commit 18a25e95b7c7926222ea164c3ab15f95f92b5f0b
10 changes: 10 additions & 0 deletions systray/exec_darwin.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,18 @@ void runApplication(const char *path, const char **argv, int argc) {
}
*/
import "C"
import (
"os/exec"
"path/filepath"
)

func execApp(path string, args ...string) error {
if filepath.Ext(path) != ".app" {
// If not .app, fallback to standard process execution
cmd := exec.Command(path, args...)
return cmd.Start()
}

argc := C.int(len(args))
argv := C.makeCharArray(argc)
for i, arg := range args {
Expand Down