MODULECMD(1)

πŸ“¦ version 5.7.0, in arch rolling, centos-stream 10

πŸ’… MODULECMD(1) β€” the Modules manual, bestie edition πŸŽ€

ok so you opened the modulecmd page (section 1 of the Modules manual, hi πŸ‘‹) and honestly? you're in the engine room now. buckle up ✨


🌸 NAME 🌸

modulecmd β€” a generic wrapper that points at the Modules execution engine. that's it, that's the vibe 🫢


⭐ SYNOPSIS ⭐

modulecmd shell [switches] [sub-command [sub-command-args]]

πŸ’– DESCRIPTION πŸ’–

okay so modulecmd is a generic wrapper β€” it just points over at the Modules execution engine, modulecmd.tcl. literally a little signpost with main character energy πŸ‘‘

modulecmd.tcl is the low-level execution engine of the Environment Modules system. bestie, this is the one doing the actual work: it evaluates modulefile logic and emits shell-specific commands that modify the user's environment. ate and left no crumbs πŸ”₯

and here's the important plot twist β€” unlike the user-facing module command, modulecmd.tcl does not directly alter the environment. nope πŸ™ˆ instead it writes shell code to standard output, which must be evaluated by the calling shell. it's giving "i made you a playlist, you gotta press play yourself" 🎧

so the module shell function or wrapper script invokes modulecmd.tcl internally and evaluates its output to actually apply the environment changes. teamwork, slay 🀝

these are the supported shells, and yes the list is long, she's thorough πŸ’…:

sh, csh, tcsh, bash, ksh, zsh, fish, cmd, pwsh, python, perl, ruby, tcl, cmake, r and lisp

πŸ“š for the full lore, go peek at the Modulecmd startup, Command line switches and Module Sub-Commands sections in the module man page. iykyk ✨

ngl, direct invocation of modulecmd is primarily intended for debugging and advanced usage. end users should normally use the module command instead β€” that's the friendly front door, this is the secret staff entrance πŸšͺπŸ¦‹


πŸ¦‹ EXIT STATUS πŸ¦‹

modulecmd exits with 0 on successful execution. otherwise 1 is returned. no in-between, no "it's complicated" πŸ’€


πŸŽ€ ENVIRONMENT πŸŽ€

see the ENVIRONMENT section in the module man page for the whole rundown πŸ’œ


🌈 FILES 🌈

see the FILES section in the module man page, all the deets live there πŸ“‚βœ¨


πŸ‘‘ SEE ALSO πŸ‘‘

  • envml
  • ml
  • module
  • modulefile

go read them, they're iconic, all of them 🌟


1996-2026, Modules Contributors 🫢

and that's a wrap, bestie β€” brought to you by version 5.7.0, dated 2026-09-21. go forth and configure your environment, you absolute legend πŸ’…πŸŒΈπŸ’–

πŸ“¦ where this page comes from