aces / cbrain

CBRAIN is a flexible Ruby on Rails framework for accessing and processing of large data on high-performance computing infrastructures.
GNU General Public License v3.0
70 stars 43 forks source link

utility module make folders #1343 #1348

Open MontrealSergiy opened 12 months ago

MontrealSergiy commented 12 months ago

see #1343 for details

prioux commented 12 months ago

The code to make the directories should not be performed in a method that is meant to return a descriptor to the framework. It should be done in "setup", that's the proper place where everything related to preparing a work directory is supposed to happen.

prioux commented 12 months ago

Actually I double checked, the on-disk invoke struct is created during 'cluster_commands()' so that's the method you need to override instead of setup().

MontrealSergiy commented 12 months ago

So do I keep old version (with minor improvements in variable names and plus of course), or should I avoid altering the command line and created subfolders directly instead?

prioux commented 12 months ago

Don't modify the command line. Just writ the ruby code that run the mkdir. That's it.

MontrealSergiy commented 12 months ago

ok. Another possibility is to factor out invocation struct massaging into separate method, so setup can be used

MontrealSergiy commented 11 months ago

Done.

(adjusted to create subfolders asap)

MontrealSergiy commented 10 months ago

As agreed in person with Pierre, the method cluster_commands() is modified (but in a more complex way than at the first attempt)