5

When I startup spacemacs I get the following message:

You appear to be setting environment variables ("PATH") in your .bashrc or .zshrc: those files are only read by interactive shells, so you should instead set environment variables in startup files like .profile, .bash_profile or .zshenv. Refer to your shell's man page for more info. Customize exec-path-from-shell-arguments' to remove "-i" when done, or disableexec-path-from-shell-check-startup-files' to disable this message

What are the usual variables spacemacs\emacs expects to find in the profile, especially the emacs related ones?

vfclists
  • 1,347
  • 1
  • 11
  • 28

2 Answers2

5

This is a feature of the emacs package exec-path-from-shell, https://github.com/purcell/exec-path-from-shell. The message is trying to do you a favour in warning about PATH variable definitions in configuration files that are not read by non-interactive shells.

Many Emacs commands use command line programs to do the real work. The package reads your PATH setup to find out all places you have these executable files.

Just like the message says.

Heikki
  • 2,961
  • 11
  • 18
5

By default, Emacs does not look at your shell config files.

The behaviour you are seeing is on account of a third-party elisp package named exec-path-from-shell which you have installed. Maybe spacemacs installs this by default.

This will probably help:

M-x finder-commentary RET exec-path-from-shell RET

phils
  • 48,657
  • 3
  • 76
  • 115