mirror of
https://github.com/Pmodules/Pmodules.git
synced 2026-06-27 10:03:08 +02:00
modulefile: bugfix in modifying PATH
This commit is contained in:
+3
-1
@@ -17,6 +17,8 @@ Pmodules are a hierarchical module environment based on Environment Modules.
|
||||
if { [module-info mode load] } {
|
||||
set PATH ":$::env(PATH):"
|
||||
if { [regexp -- {.*:(.*/Pmodules/[^:]*):} $PATH -> str] } {
|
||||
remove-path PATH $str
|
||||
if { [string compare $str $PREFIX/bin] != 0 } {
|
||||
remove-path PATH $str
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user