methlabUZH / automagic

Automagic
GNU General Public License v3.0
89 stars 32 forks source link

Possible compatibility improvement - Automagic as submodule #56

Closed ramBrain closed 2 years ago

ramBrain commented 2 years ago

Dear developers,

I am currently using Automagic as a submodule in a larger repository. However, there is currently a lack of compatibility for such usage.

Specifically, in PreprocessingConstants.m, the Automagic paths are searched for based on the "automagic" string. However, when installing Automagic as a submodule in a larger repository, an "automagic" folder also exists in the .git subdirectory, which does not contain the actual toolbox but only information on the repository history. This might produce errors when trying for example to retrieve the plugin zip files. A possible fix could just be right after line 97, by adding:

parts(contains(parts,'.git')) = [];

By adding this, one can be sure that only the actual automagic folder is retrieved.

Would you agree with this?

Thank you, Ramtin

ksgfan commented 2 years ago

Hi Ramtin

it should be fine, I don't see any problem with this solution.

sorry for the late response Best, Dawid