PecanProject / pecan

The Predictive Ecosystem Analyzer (PEcAn) is an integrated ecological bioinformatics toolbox.
www.pecanproject.org
Other
203 stars 235 forks source link

load.bety.sh doesn't clean up if error #200

Closed mdietze closed 10 years ago

mdietze commented 10 years ago

I've been noticing that if there's any error in the load.bety.sh database sync (non-conforming schemas, tables with invalid values) that the script doesn't clean up after itself, but instead just leaves the folder in /tmp. Since out /tmp is pretty small, this means that I regularly (every couple days) have to go an clean it out manually. Would be nice if the script was a bit more robust.

robkooper commented 10 years ago

Added a new variable called KEEPTMP which is NO by default. If this is YES it will keep the tmp folder, otherwise it will delete the tmp folder if the synchronization failed.