Dear SNAP community and Team, thank you all so much for the amazing SNAP software! Hopefully a quick/easy question…
Although I’m very comfortable with building SNAP from source:
And there are plenty of instructions for running/debugging SNAP from an IDE:
Once I have built SNAP from source, I would like to run the SNAP I have built: without using an IDE.
Are there instructions available for doing that?
Thanks in advance and apologies if this question was asked elsewhere
The SNAP Team does not provide such instructions.
But as SNAP runs with Java the general approach should work.
Here is an example tutorial: How to Debug Java on the Command Line | foojay
May I ask why do you want to do it? I consider this as very inconvenient and can hardly imagine a use case.
Thanks v much for your message. Mostly for automation / reproducibility. Also being more comfortable with the command line. Ideally what I wanted to do was type “run” and hit return (after building the SNAP from source) without going into an IDE. Thanks much for the link, hopefully can figure it out. Was curious if others have done that before!
You can use the run configuration shown in the IDE Guide to configure a java cmd call. It is pretty similar.
You could also add the Exec Maven Plugin to the pom. Then it could be just one call to build and execute SNAP.
Thanks v much @marpet, really appreciate your help
Correlating your instructions with some of the other threads, here’s the procedure arrived at (thanks again):
cd /home/username/GitHub/snap/snap-desktop/snap-application/target/snap/bin # enter the folder with the entry point
vim ../etc/snap.conf # edit the parameters incl. the cluster parameter
# clusters' paths separated by path.separator (semicolon on Windows, colon on Unix). Path needs to be full/explicit. And, for example to add s2tbx shown only:
./snap # run snap with the clusters indicated in the ../etc/snap.conf file ```
Thanks again @marpet for helping me get there! Might be nice to have that or related procedure on the how to page but no worries (the how to does say to check the forums!), might try a small pull request on the document page if that part of the documentation was on GitHub.
Thanks again for the great software and community and thanks for your availability here.
Much appreciated, cheers