Skip to main content

Timeline for How can I edit the $PATH on linux?

Current License: CC BY-SA 2.5

5 events
when toggle format what by license comment
Apr 5 at 8:54 comment added Anton Samokat Can be used semicolon to separate commands on the same line: PATH=$PATH:newPath1:newPAth2; export PATH
Oct 15, 2012 at 21:58 history migrated from stackoverflow.com (revisions)
May 26, 2009 at 11:05 comment added Glen It depends on the shell you're using. On Solaris (I know the question is about Linux) one of the shells (can't remember which one off the top of my head) requires that you do the export separately from setting the value in a script. So I've just gotten into the habit of doing it on 2 lines.
May 26, 2009 at 11:03 comment added Chris Lutz I think you can do that all on one line if you want to. export PATH=$PATH:newPath1:newPAth2
May 26, 2009 at 10:54 history answered Glen CC BY-SA 2.5