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

Adds $FSL_SITE_CONFIG_DIR as a place for cmaps and luts #121

Closed

Conversation

captainnova
Copy link

Hi,

Our lab has several custom colo(u)rmaps and luts, and we would like all our users to be able to use them, with custom ordering of the selection menus, without doing any user-level configuration. I had set them up and edited order.txt in fsleyes.assetsdir, which worked until an fsleyes update overwrote the order.txts. It would be much better to have such site configuration outside the FSL/fsleyes installation directories, so this PR gets at least the cmap/lut lookup to check $FSL_SITE_CONFIG_DIR as a possible 3rd location of cmaps, luts, and order.txts.

The priority order is user > site > builtin.

Rob Reid
Mayo Clinic

@pauldmccarthy
Copy link
Owner

Hi @captainnova, thanks - this is a great idea. I'm teaching this week, so will have a play when I get a chance. One request I will make though - can we call the variable $FSLEYES_SITE_CONFIG_DIR instead?

@captainnova
Copy link
Author

can we call the variable $FSLEYES_SITE_CONFIG_DIR instead?

Sure. I was hoping that the idea could also eventually be applied to FSL too, e.g. FSLOUTTYPE and fsl_sub, etc., but our immediate itch was with fsleyes and its source was more accessible.

But if you would rather keep the config dirs a bit more separate we can certainly work with $FSLEYES_SITE_CONFIG_DIR and hopefully eventually $FSL_SITE_CONFIG_DIR as well.

@captainnova
Copy link
Author

Hi, I'm wondering if the PR is ready to go?

@pauldmccarthy
Copy link
Owner

Hi @captainnova, sorry - I've been busy with other work. I'll get this merged and released as soon as I have a moment - I should be able to within a week or two.

@captainnova
Copy link
Author

sorry - I've been busy with other work.

No problem, and no rush. I was just checking in case it had been forgotten, since I knew you were busy teaching a couple of weeks ago.

@pauldmccarthy
Copy link
Owner

Hi @captainnova, thanks for your patience - I've just released version 1.10.0 which includes this enhancement. I refactored the code in colourmaps.py to make it a little less clunky (it was clunky before your changes), and also extended it to support storing default command-line arguments and custom layouts in $FSLEYES_SITE_CONFIG_DIR.

Thanks!

(PR closed rather than merged, as I maintain the code on our internal gitlab

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

Successfully merging this pull request may close these issues.

2 participants