File: rc

package info (click to toggle)
modules 4.6.1-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 19,932 kB
  • sloc: exp: 35,889; ansic: 10,653; sh: 3,920; makefile: 1,316; tcl: 612; csh: 178; python: 169; perl: 118; ruby: 44
file content (15 lines) | stat: -rw-r--r-- 515 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#%Module

# ensure MODULEPATH is always defined, use content of .modulespath config file
# to initialize it if not defined
if {![is-used] && [file readable /usr/share/Modules/init/.modulespath]} {
    set fid [open /usr/share/Modules/init/.modulespath r]
    set fdata [split [read $fid] "\n"]
    close $fid
    foreach fline $fdata {
        if {[regexp "^\\s*(.*?)\\s*(#.*|)\$" $fline match patharg] == 1
            && $patharg ne {}} {
            eval module use --append [split $patharg :]
        }
    }
}