Re: Perl Env::Modulecmd
Manage your shell environment variables and aliases
Brought to you by:
leomania,
xdelaruelle
From: Ron I. <Ron...@mo...> - 2001-07-11 19:41:59
|
Hi Mark -- (cc'ing to modules-interest with explanations) Mark Lakata wrote: > > Is this different from the standard perl interface? > > require "$ENV{MODULESHOME}/init/perl"; > module("load","fred/1.0"); > module("unload","sheila/4.5b"); It's similar in theory, but it does quite a bit more error checking, and gives you a nicer syntax. Also, (depending on usage) it loads modules at compile-time so the environment is always prepared before runtime begins. This can be important if you have Perl code that depends on the environment for its initialization. > Actually, I had trouble installing the package: [...] > I think this is because "modulecmd" is not on my path... now we've got a > chicken/egg problem: how do you add 'modulecmd' to the path if the > Env::Modulecmd isn't loaded yet ? :) Heh... indeed. This depends on modulecmd being in the path, and $MODULEPATH being set. You can set $PERL_MODULECMD to get around the first one... but it seems the init code that comes with 3.0.0 does some other fancy things for you. We still use 2.2.1.1, and we don't use the init functions or the .modulespath file, so I never came across this. Perhaps another release that addresses these is in order. Stay tuned! Thanks for the feedback. -- Ron Isaacson Morgan Stanley ron...@mo... / (718) 754-2345 |