I always wondered about this but never found a way to do it. Say I have two terminals open and I want to save the current path in a variable and read it from the second terminal that I have open. Then in the first terminal I type:
And in the second I type:Code:A=$(pwd)
that doesn't work though. I have tryied also withCode:echo $A
andCode:export A=$(pwd)
but nothing seems to work. Is there a way to do this?Code:alias A=$(pwd)
Bookmarks