the default .profile does not export PATH, still the PATH set there is available to all processes.

How does that work?


If there is already an exported shell variable, then subsequent resetting of the variable will automatically export it. So in this case, if you run "env" prior to where .profile sets PATH, you will probably see it was previously set / exported (either in /etc/profile, /etc/bash_profile, or somewhere else).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.