> chad <yand...@gmail.com> writes:

> I think the aspect which confuses most people under macOS is that the
> 'dock' does not run as a child process of the user's login shell. This
> means it does not see any of the environment variables (such as PATH)
> which the user may have added to in their login .profile. 

Very much so.


> Common complaint is that everything seems to work when they run Emacs
> from within a terminal, but not when they start it via the 'Icon'
> (either from the 'Applications' view in finder or the dock). It works
> from within the terminal because the terminal has run a shell which
> has sourced their login profiles (for simplicity, I'm ignoring the
> subtle differences between .profile/.bash_profile and .bashrc or
> .zprofile and .zxhrc, especially as lots of people now put many
> environment settings in .bashrc rather than .profile these days. Same
> with the differences between configuring the terminal app to run a
> login shell or just a 'normal' shell i.e. there is some devil in the
> details!).

Oops so do I (I even use the tcsh shell (via fink)


> The xattr command has little to do with the security restrictions on the
> mac. In fact, even GNU Linux has the xattr command. The restrictions
> added by macOS are a whole additional layer.

That is important to know, thanks


> The exec-path-from-shell package is a common mechanism used to ensure
> the path is configured to include additional directories and is
> primarily needed because starting Emacs from the dock or Applications
> folder does not run the process as a child of the user's login shell.
> Another approach is to add the paths to either the /etc/paths or put
> them in a file in /etc/paths.d, which sets the system wide paths which

I'd rather prefer not to mess up with these files, or only as a method
of last resort.

> all applications will then see. Of course, this doesn't solve the issue
> of other environment variable settings which might be needed. For
> simplicity, I will often just add these directly in my init.el, but this
> isn't optimal as now you have two places to maintain such things (from
> memory, I think the exec-path-from-shell package can help with these
> more general non-path environment settings as well). 

Right I think I will give that exec-path-from-shell a try.

Thanks

Uwe 


-- 
I strongly condemn Putin's war of aggression against the Ukraine.
I support to deliver weapons to Ukraine's military. 
I support the ban of Russia from SWIFT.
I support the EU membership of the Ukraine. 

Attachment: smime.p7s
Description: S/MIME cryptographic signature

Reply via email to