-
-
Notifications
You must be signed in to change notification settings - Fork 184
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
[General]: exec-paths not being set in Sequoia for emacs-plus@30 #720
Comments
Hmm; just tested with -q and the embedded paths are showing up, so it seems it might be a weird interaction with something in my .emacs and Sequoia. I'll poke around and will follow up or close this soon. FOLLOWUP: Oops that was just because I ran |
Can you double check that If it is, I have no clues why on Sequioia it doesn't work and I am not going to upgrade on my laptops as I need them stable - can't afford something to break :) But I will try to get my hands on another machine to test. |
Hi all. I had made the mistake of downgrading to emacs-plus@29 to resolve this before realizing that it was likely the upgrade to a beta of the upcoming macOS version. One curious thing I've noticed is that while clicking on the .app bundle does not set the path, if you click on the executable within the bundle (Emacs.app/Contents/MacOS/Emacs), the path from Info.plist will be set. Likewise, the path will be set correctly if you click on the Bash script at /usr/local/Cellar/emacs-plus@##/##.#/bin/emacs that calls (exec) the executable. |
Sorry for the slow reply here, but just checked and can confirm that the PATH in the plist seems to be correct; it's just somehow not ending up applied. Also just confirmed this is still happening on the release version of Sequoia in case you're planning on upgrading at this point and can try to repro. |
That's a shame. I was hoping (though imagining it would be unlikely) that it would be resolved in the finalized Sequoia release. I've not been able to upgrade from the beta though. as AFAICT, the beta is being classified by the OS itself as the release. Either that, or my upgrade from the beta to the release took all of 1-2 mins when I restarted the computer last night. |
I will try to upgrade one of my machines to Sequoia ASAP (still need to plan to do it without any potential work disruptions), but meanwhile you can use https://github.com/purcell/exec-path-from-shell |
Ok, so I've upgraded one of my laptops and I can confirm the difference in behaviour between Sequoia and previous OS version. Test 1
Result: plist contains all the correct values, but when I start Emacs.app from Finder the PATH value (I inspect it using Test 2Emacs 29.4-1 from Emacs For macOS. Result: the PATH value matches the one I have in Terminal session. I don't fully understand what's happening and what has changed. But it seems that there is something happening even in Sonoma. Maybe I am just tired and made a mistake in my tests 🤷 |
On Emacs 29: I just upgraded to Sequoia and I am getting this problem as well. I can see my intended (getenv "PATH")
"/usr/bin:/bin:/usr/sbin:/sbin" If I run Using exec-path-from-shell is working for me in the interim until we figure this problem out. |
@d12frosted Emacs for macOS appears to use a Rust launcher that gets and sets the environment variables: https://github.com/caldwell/build-emacs/blob/master/launch.rs#L101 In other words, it appears to have exec-path-for-shell built-in. This is convenient, but likely increases startup time in the same way that exec-path-for-shell does. Would need to test, and it'd be dependent on a person's shell initialization scripts. |
The strangest thing to me is that, emacs-plus even doesn't respect
Theoretically, even the path injection does not work, then the app should still read from the login shell configuration file, right? |
@milanglacier Not on macOS, at least not to my knowledge. Until the PATH injection, we always had to use |
My understanding is that, while macOS apps launched from finder do not read from the interactive shell configuration file (aka And this is not the case for emacs, which is so weird. |
Ok, I find another way to use the finder to open emacs, by using the
we can also change the icon to the emacs icon following what kitty suggested: kitty's tutorial In this way, I do not need to use the |
Issue description
I just updated my setup to beta 7 of macOS Sequoia and noticed that the path values embedded in the Emacs.app's plist no longer seem to be getting applied. I did a fresh uninstall/reinstall of emacs-plus@30 to no avail. It seems the values get inserted into the plist correctly but emacs doesn't seem to be applying them.
For now I'm just manually setting exec-path to what the plist contains in my .emacs so I'm all good, but wanted to mention this just to get it on the radar since Sequoia RC is likely a week or two out. Anyone else running the beta and seeing this same behavior?
The text was updated successfully, but these errors were encountered: