Page 1 of 1

Question about OCSSW_bash.env

Posted: Thu May 06, 2021 9:48 pm America/New_York
by roxani2018
Hi,

I met a problem when I try to source $OCSSWROOT/OCSSW_bash.env: "/Applications/seadas-7.5.3/ocssw/OCSSW_bash.env:136: = not found". I am not sure what's going on since it worked well before.
How should I solve this problem? THANKS.

Roxani

Re: Question about OCSSW_bash.env

Posted: Fri May 07, 2021 8:01 am America/New_York
by gnwiii
It looks like you are using macOS (what version?) and SeaDAS 7 but something has changed.

The "= not found" error occurs when a bash-specific script is run with zsh (current default macOS shell, which gives a "%" command prompt). See: "https://www.zsh.org/mla/users/2011/msg00161.html". I think the SeaDAS 8 OCSSW_bash.env works with zsh.

The error suggests something replaced bash in your terminal with zsh. In your terminal, you can try running bash, which should change the command prompt from "%" to "$", and then "source $OCSSWROOT/OCSSW_bash.env". Some Terminal applications have options to specify which shell is used.

See: https://www.howtogeek.com/444596/how-to ... -catalina/ for more detailed explanations with screen captures.

You can edit OCSSW_bash.env to be zsh compatible. It may be useful to learn how to do this as you may encounter other bash-specific scripts.

Re: Question about OCSSW_bash.env

Posted: Sat May 08, 2021 5:29 am America/New_York
by roxani2018
Hi!

Thanks a lot for your kindly help.
I use zsh on macOS 10.13.6 and SeaDAS 8 (replace of v7.5.3) works well now.
However a new problem comes up when I use getanc.py to catch ancillary data file: "command not found: getanc.py", it may regards to upgrade of SeaDAS but I am not clear how to solve it. Could you please help me with this new problem?

Best wishes,
Roxani

Re: Question about OCSSW_bash.env

Posted: Sat May 08, 2021 8:38 am America/New_York
by OB.DAAC - SeanBailey
With SeaDAS 8, most of the python scripts are now 'installed' under $OCSSWROOT/bin and have had the '.py' extension removed. The getanc.py script is one of those, so you can simply drop the .py from the call and it should work.

Sean

Re: Question about OCSSW_bash.env

Posted: Sat May 08, 2021 10:50 am America/New_York
by roxani2018
Dear Sean,

I have done as suggested and it works.
Thank you for the quick feedback and it helps a lot.

Best wishes,
Roxani