On Thu, May 9, 2024 at 2:17 PM Ilya Kulakov <kulakov.ilya@xxxxxxxxx> wrote: > Both "Visualize <branch>'s History" and "Visualize All Branch History" do nothing on macOS. In the terminal it logs: > > Error in startup script: 58:103: execution error: Not authorized to send Apple events to System Events. (-1743) > "if {[tk windowingsystem] eq "aqua"} { > exec osascript -e [format { > tell application "System Events" > set frontmost of processes ..." > (file "/opt/homebrew/bin/gitk" line 12321) The above is reporting that the problem is in the `gitk` script... > The relevant code at https://github.com/git/git/blob/0f3415f1f8478b05e64db11eb8aaa2915e48fef6/git-gui/git-gui.sh#L271-L279 should not be fatal, because the permission to access "System Events" and arbitrarily manipulate windows is optional. ... but the code you cited here is the git-gui script, which does not experience the same problem because a `catch` block is wrapped around the `exec osascript` invocation. A patch to fix this problem in `gitk` was posted[1] in 2018 but never got picked up since the `gitk` maintainer seems to have disappeared. Considering that the patch is still relevant, perhaps it might make sense for Junio to pick it up himself and apply it to the Git tree(?). [1]: https://lore.kernel.org/git/20180724065120.7664-1-sunshine@xxxxxxxxxxxxxx/