Hacker News new | ask | show | jobs
by justinsaccount 1950 days ago
don't forget about CDPATH

  $ export CDPATH=~/Workspace/src/github.com # in .bashrc
  $ cd brigad/ops
1 comments

In my experience, CDPATH is a great way to lose hours chasing down errors throughout your scripts.
"CDPATH=<str>" without the export will work as you'd want, and won't pollute the environment for subshells and scripts. It is unlikely you really want to export anything listed in the shell variables section of the man page, but yeah everybody does :/

[This message brought to you by https://news.ycombinator.com/item?id=22978770]

TIL, thanks :)