A bash script is running as I defined it in Startup Applications. It is possible to display on terminal a variable used in that script? If yes, how?
Tell me more
×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.
|
The quick answer (assuming this is a bash script as tagged) is no, variables are not shared between separate shell instances. The only way I know of to access a variable from a script started in a different shell is to have the script write the variable to a file and then access that file. |
|||||||
|


echo "$var"? – Hauke Laging Jun 8 at 14:23