On 05-07-16 13:01, Erik Smeets wrote: > > The problem in our opinion would be that a user wouldn't return to a clean > environment when unloading the modules. Furthermore, this complicates > switching between different versions. What's your thought on this and how do > you approach these requirements within your systems?
You have several options: - re-implement all the logic from the bashrc file in the module file itself. Downside: lots of work and maintain heavy. - Create OpenFOAM wrapper that does the source for you. In that way the environment is never polluted. - Always go to a subshell before sourceing the file. We don't have much trouble with it because it's used most often within a job file and not that many people switch OpenFOAM modules. But you're right, it's not very clean. Ward