Description
The line:
ISIS_ROOT = os.environ.setdefault('ISISROOT', '/usgs/pkgs/isis3/isis')
in pysis.env
is all what controls where to find ISISROOT.
I have found this very fickle in trying to make things work across several conda environments (which is now the default install for ISIS3
), so I propose to add functionality to pysis.env.py
to get the paths from a config file in the users' home.
Currently, this file on my side simply looks like this:
$ cat .isisroot.toml (isis3)
ISISROOT = '/Users/klay6683/miniconda3/envs/isis3'
ISIS3DATA = '/isis3/data'
and I'm using the toml
format (https://github.com/toml-lang/toml).
I'm thinking about a few approaches how this fluently could be combined with an existing os.enviroment variable, but let's discuss these details in my PR I gonna start later this week after my current meeting is over (where, of course, I needed pysis to work and it didn't ;) ).
We could also have this config file to be created after the current ISIS3
install, it's simple enough. But much more stable against environment variable manipulations caused by switching conda envs (admittedly, that's the whole idea of conda, obviously).