Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't hardcode installation path of CAT12 to be inside toolbox directory #3

Closed
gdevenyi opened this issue Sep 8, 2022 · 1 comment

Comments

@gdevenyi
Copy link

gdevenyi commented Sep 8, 2022

The path to CAT12 is hard-coded to be inside the toolbox directory of the SPM12 installation:
https://github.com/ChristianGaser/cat12/blob/main/spm_cat12.m#L43

But SPM12 allows modification of toolbox directory path via spm_get_defaults('tbx') it will iterate over all directories defined in the variable and load toolboxes there:
https://github.com/neurodebian/spm12/blob/master/spm.m#L943-L977

I use this to install SPM toolboxes into lmod modules to provide proper versioning (see #2 for an improvement request there)

fullfile(fileparts(mfilename('fullpath'))) might be a better way to locate the installation path when CAT12 loads.

@ChristianGaser
Copy link
Owner

Thanks for the advice. I have changed all hardcoded paths.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants