Possible Duplicate:Different ways to execute a shell script What happens when I issue the following command:source devenv.cshHow does it differ from running it just as devenv.csh ?
What does sourcing a file mean in a shell?
shell;shell script;command
When you just run the file, the interpreter given in the shebang (the first line of the script, starting with #!, e.g. #!/usr/bin/csh) is executed with devenv (or devenv.csh, this is a bit inconsistent in the question) as a parameter. It will then execute the commands in the file and terminate.Sourceing the file means the commands are executed in the current shell. When some of the commands in devenv.csh change the environment (and the file name hints that this is the main purpose of this particular file), executing it will have no effect: the environment will be changed in the subshell, but that will terminate right away, leaving no trace of the changed settings. Note that environment variables never propagate upward: they can only be inherited by subprocesses, but not by parents.