I have been trying to setup a environment variable in Cygwin using the command export PRIMOSBASE=/directory/for/primosfiles.
And when i check the variable using the command echo $PRIMOSBASE it shows the /directory/for/primosfiles. hopeful this means the environment variable is set.
But when i try to run a shell script(primos) for the /directory/for/primosfiles, it shows
./primos: line 8: /prilaunch.pl: No such file or directory
chmod: failed to get attributes of `step1.sh': No such file or directory
which means i have not set the PRIMOSBASE environment. could anyone please tell me where i am going wrong…
Thanks …
Run
to append the command to the end of your
.bashrcfile, so that the variable is set each time you use Cygwin. Then runto make it take effect immediately.
NOTE: Make sure you use double brackets (
>>) to append. It might be a good idea to make a backup of.bashrcjust in case. If you’re not comfortable with I/O redirection, an alternative is to edit.bashrcwith an editor. I thinkvimis among the default tools in Cygwin.