ESPRI-Mod / synda

ESGF Downloader (this is a deprecated repository, the tool has now moved to https://github.com/ESGF/esgf-download)
https://espri-mod.github.io/synda/
21 stars 11 forks source link

location of shell scripts #165

Open painter1 opened 3 years ago

painter1 commented 3 years ago

I have had a hard time finding the location of shell scripts such as sdget.sh, in the latest version of the master branch. It seems to me that the real ones, i.e. the ones which Synda will run, are hidden in a tar file! This file is synda/resources/environment/tree.tar.gz and the contents are copied to /etc/synda/sdt/bin (or a similar directory) when "synda init-env" is run.

This is very surprising, if true. Am I right? If so, it would be very awkward to keep track of bug fixes and enhancements.

pjournou-ipsl commented 3 years ago

The synda init-env sub-command can be used in the two following cases only :

1 / when user wants to let synda create the tree structure (located at $ST_HOME) 2 / when user wants to recreate it (eventually)

It's right that this sub-command uses the synda/resources/environment/tree.tar.gz file.

This file is a clean synda tree structure (i.e. an useful image) used by the init-env sub-command to easily (re)build user synda environment. In the other user cases, synda does not use this tar file. When synda executes scripts as sdget.sh, it uses those located in the $ST_HOME/bin directory.

I hope that this answer will help you, but if not, don't hesitate to precise your point of view.

painter1 commented 3 years ago

Thanks for the confirmation. I look at shell scripts a little differently - not as the environment, but as a kind of code at the same level as a .py file. In particular, I have some enhancements to sdget.sh which I would like to make available for others to use. With a Python file, I would create a new branch with the enhanced version of the file, and submit it as a pull request. How would you do it with a shell script?