I am often working in a process in the Terminal and I've set some variables and used
cd and so forth. Then I'd like to open another Terminal window from there. Is there any way to do this?
You could use this little script to do what you want:
place it in one of the folders in your path, make it executable (
What you could do is the following.
Get the current environment in your clipboard:
Open up a new Terminal window and export those environment variables
And to ease the process, you could always alias it, like so
So that all you have to do is
|show 1 more comment|
To open a new Terminal window you can do open -n /Applications/Utilities/Terminal.app
or also /Applications/Utilities/Terminal.app/Contents/MacOS/Terminal &
Though I don't know if they will accept an argument such as