Say you are in /very/cool/and/deeply/nested/folder . And you want to open a new terminal tab in the same folder.
How would you do that?
I use Mac OS and Zsh.
Answer
Use Oh-My-Zsh and add the 'osx' plugin in your ~/.zshrc like:
plugins=(osx)
If you use OSX's Terminal App, you also need to add the terminalapp
plugin too: credit
plugins=(osx terminalapp)
If you use iTerm you need to set a configuration option (Note that you may not need the zsh plugins for this to work): credit
Preferences > Profiles > Default > General > Working Directory > Reuse previous session's directory option
That's all you need to do!
No comments:
Post a Comment