Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

7
  • 10
    Manually sourcing ~/.bashrc is not necesary, it happens by default. It fact, it seems to me like a bad idea. Commented Dec 25, 2016 at 3:53
  • 4
    $PATH does not expand from ~/.ssh/environment, at least not in OpenSSH_7.9p1, OpenSSL 1.1.1b 26 Feb 2019. Commented Oct 23, 2019 at 8:31
  • 2
    @Jaakko It is probably disabled in sshd_config using PermitUserEnvironment (default in recent versions) Commented Oct 23, 2019 at 8:35
  • 4
    I figured it out, it was not expanding because I added a line PATH="$PATH:/new/path" to my ~/.ssh/environment when it should have been PATH=$PATH:/new/path Commented Oct 23, 2019 at 8:42
  • 3
    On MacOS Catalina OpenSSH_8.1p1 be warned you better do $ echo "PATH=$PATH" > ~/.ssh/environment cause $PATH does not expand Commented Oct 21, 2020 at 10:58