File: r.in

package info (click to toggle)
lmod 6.6-0.2
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 16,716 kB
  • ctags: 1,336
  • sloc: sh: 3,714; python: 967; makefile: 718; tcl: 695; perl: 495; csh: 85; ansic: 35
file content (17 lines) | stat: -rw-r--r-- 343 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# -*- r -*-
module <- function(...){
  arglist <- as.list(match.call())
  ## change this from 'module' to 'r'
  arglist[1] <- 'r'
  args <- paste(arglist, collapse = ' ', sep = '')

  binary <- "@PKG@/libexec/lmod"

  cmd <- paste(binary, args, sep = ' ')

  hndl <- pipe(cmd)
  eval(expr = parse(file = hndl))
  close(hndl)

  invisible(0)
}