source in bash
Hi,
What does source do? (i tried man source but it said it was a built in command) I have an executable file that exports some path variables called d86 . When I'm logged in as root all i need to do is type d86 and it sets the path. But when I'm not logged in as root i have to type source d86 for the path to be set. So I'm just wondering what source is and why i need it in one case and not the other. Thanks -AB |
In essence, it's like you're running a "batch" file.
When you source a script, the shell processes the script as if you had typed in all of the script's commands by hand. It's a very powerful command, and is used ALOT in the Unix/Linux world. |
for more info try
man bash ;) |
All times are GMT -5. The time now is 04:42 PM. |