===========================
step 1
lua ProjectDIR/src/lmod.in.lua shell --regression_testing --version
===========================
Modules based on Lua: Version 8.7.63 2025-06-27 15:32 -05:00
    by Robert McLay mclay@tacc.utexas.edu
===========================
step 2
buildSh2MF ProjectDIR/rt/sh_to_mf/tstScript.sh
===========================
===========================
step 3
buildSh2MF --to TCL ProjectDIR/rt/sh_to_mf/tstScript.sh
===========================
===========================
step 4
buildSh2MF ProjectDIR/rt/sh_to_mf/path_both_ends.sh
===========================
===========================
step 5
buildSh2MF --from csh ProjectDIR/rt/sh_to_mf/cshScript.csh
===========================
===========================
step 6
buildSh2MF ProjectDIR/rt/sh_to_mf/broken.sh
===========================
Error found in sourcing script "ProjectDIR/rt/sh_to_mf/broken.sh":
ProjectDIR/rt/sh_to_mf/broken.sh: line 3: fooBar: command not found
If this is a bash script please try:
  $ set -exv; . ProjectDIR/rt/sh_to_mf/broken.sh
See https://lmod.readthedocs.io/en/latest/260_sh_to_modulefile.html for details.
===========================
step 7
buildSh2MF ProjectDIR/rt/sh_to_mf/unalias.sh
===========================
Error found in sourcing script "ProjectDIR/rt/sh_to_mf/unalias.sh":
If this is a bash script please try:
  $ set -exv; . ProjectDIR/rt/sh_to_mf/unalias.sh
See https://lmod.readthedocs.io/en/latest/260_sh_to_modulefile.html for details.
===========================
step 8
buildSh2MF ProjectDIR/rt/sh_to_mf/spack_foo.sh
===========================
===========================
step 9
buildSh2MF ProjectDIR/rt/sh_to_mf/tst2.sh
===========================
===========================
step 10
lua ProjectDIR/src/lmod.in.lua shell --regression_testing show wrapperSh/1.0
===========================
   ProjectDIR/rt/sh_to_mf/mf/wrapperSh/1.0.lua:
 source_sh("bash","ProjectDIR/rt/sh_to_mf/tstScript.sh")
append_path("LD_LIBRARY_PATH","/abc/def")
append_path("LD_LIBRARY_PATH","/def/qrst")
setenv("MY_NAME","tstScript.sh")
setenv("PTH","ProjectDIR/rt/sh_to_mf/bin:ProjectDIR/proj_mgmt:PATH_to_TM:ProjectDIR/rt/sh_to_mf/sbin")
setenv("TST_SCRIPT","1")
set_alias("fooAlias","foobin -q -l")
set_shell_function("banner"," \
    local str=\"$1\";\
    local RED='\\033[1;31m';\
    local NONE='\\033[0m';\
    echo \"${RED}${str}${NONE}\"\
","")
set_shell_function("fooFunc"," \
    echo \"arg1: $1\"\
","")
set_shell_function("junk"," \
    if [ -n \"${ZSH_VERSION:-}\" ]; then\
        \\echo \"junk\";\
    fi\
","")
set_shell_function("my_help"," \
    echo \"do not forget \\\"foo\\\"\"\
","")
set_shell_function("save_args"," \
    for arg in \"$@\";\
    do\
        printf \"%s\\n\" \"$arg\" | sed -e \"s/'/'\\\\\\\\''/g\" -e \"1s/^/'/\" -e \"\\$s/\\$/' \\\\\\\\/\";\
    done;\
    echo \" \"\
","")
complete("bash","xyz123","-F _xyz123")
setenv("MY_NAME","tstScript.sh")
 source_sh("bash","ProjectDIR/rt/sh_to_mf/second.sh arg1")
setenv("SECOND","FOO_BAR")
===========================
step 11
lua ProjectDIR/src/lmod.in.lua shell --regression_testing load wrapperSh/1.0
===========================
===========================
step 12
lua ProjectDIR/src/lmod.in.lua shell --regression_testing show wrapperSh/1.0
===========================
   ProjectDIR/rt/sh_to_mf/mf/wrapperSh/1.0.lua:
 source_sh("bash","ProjectDIR/rt/sh_to_mf/tstScript.sh")
append_path("LD_LIBRARY_PATH","/abc/def")
append_path("LD_LIBRARY_PATH","/def/qrst")
setenv("MY_NAME","tstScript.sh")
setenv("PTH","ProjectDIR/rt/sh_to_mf/bin:ProjectDIR/proj_mgmt:PATH_to_TM:ProjectDIR/rt/sh_to_mf/sbin")
setenv("TST_SCRIPT","1")
set_alias("fooAlias","foobin -q -l")
set_shell_function("banner"," \
    local str=\"$1\";\
    local RED='\\033[1;31m';\
    local NONE='\\033[0m';\
    echo \"${RED}${str}${NONE}\"\
","")
set_shell_function("fooFunc"," \
    echo \"arg1: $1\"\
","")
set_shell_function("junk"," \
    if [ -n \"${ZSH_VERSION:-}\" ]; then\
        \\echo \"junk\";\
    fi\
","")
set_shell_function("my_help"," \
    echo \"do not forget \\\"foo\\\"\"\
","")
set_shell_function("save_args"," \
    for arg in \"$@\";\
    do\
        printf \"%s\\n\" \"$arg\" | sed -e \"s/'/'\\\\\\\\''/g\" -e \"1s/^/'/\" -e \"\\$s/\\$/' \\\\\\\\/\";\
    done;\
    echo \" \"\
","")
complete("bash","xyz123","-F _xyz123")
setenv("MY_NAME","tstScript.sh")
 source_sh("bash","ProjectDIR/rt/sh_to_mf/second.sh arg1")
setenv("SECOND","FOO_BAR")
===========================
step 13
lua ProjectDIR/src/lmod.in.lua shell --regression_testing refresh
===========================
===========================
step 14
lua ProjectDIR/src/lmod.in.lua shell --regression_testing list
===========================
Currently Loaded Modules:
  1) wrapperSh/1.0
===========================
step 15
lua ProjectDIR/src/lmod.in.lua shell --regression_testing --mt
===========================
_ModuleTable_ = {
  MTversion = 3,
  c_rebuildTime = false,
  c_shortTime = false,
  depthT = {},
  family = {},
  mT = {
    wrapperSh = {
      fn = "ProjectDIR/rt/sh_to_mf/mf/wrapperSh/1.0.lua",
      fullName = "wrapperSh/1.0",
      loadOrder = 1,
      mcmdT = {
        ["ProjectDIR/rt/sh_to_mf/second.sh arg1"] = {
          [[setenv("SECOND","FOO_BAR")]],
        },
        ["ProjectDIR/rt/sh_to_mf/tstScript.sh"] = {
          [[append_path("LD_LIBRARY_PATH","/abc/def")]], [[append_path("LD_LIBRARY_PATH","/def/qrst")]], [[setenv("MY_NAME","tstScript.sh")]], [[setenv("PTH","ProjectDIR/rt/sh_to_mf/bin:ProjectDIR/proj_mgmt:PATH_to_TM:ProjectDIR/rt/sh_to_mf/sbin")]], [[setenv("TST_SCRIPT","1")]], [[set_alias("fooAlias","foobin -q -l")]], [=[set_shell_function("banner"," \
    local str=\"$1\";\
    local RED='\\033[1;31m';\
    local NONE='\\033[0m';\
    echo \"${RED}${str}${NONE}\"\
","")]=], [[set_shell_function("fooFunc"," \
    echo \"arg1: $1\"\
","")]], [=[set_shell_function("junk"," \
    if [ -n \"${ZSH_VERSION:-}\" ]; then\
        \\echo \"junk\";\
    fi\
","")]=], [[set_shell_function("my_help"," \
    echo \"do not forget \\\"foo\\\"\"\
","")]], [[set_shell_function("save_args"," \
    for arg in \"$@\";\
    do\
        printf \"%s\\n\" \"$arg\" | sed -e \"s/'/'\\\\\\\\''/g\" -e \"1s/^/'/\" -e \"\\$s/\\$/' \\\\\\\\/\";\
    done;\
    echo \" \"\
","")]], [[complete("bash","XyZ123","-F _xyz123")]],
        },
      },
      propT = {},
      stackDepth = 0,
      status = "active",
      userName = "wrapperSh/1.0",
      wV = "000000001.*zfinal",
    },
  },
  mpathA = {
    "ProjectDIR/rt/sh_to_mf/mf",
  },
  systemBaseMPATH = "ProjectDIR/rt/sh_to_mf/mf",
}
===========================
step 16
lua ProjectDIR/src/lmod.in.lua shell --regression_testing unload wrapperSh/1.0
===========================
===========================
step 17
lua ProjectDIR/src/lmod.in.lua shell --regression_testing load brokenSh/1.0
===========================
Lmod has detected the following error: Error found in sourcing script "ProjectDIR/rt/sh_to_mf/broken.sh":
ProjectDIR/rt/sh_to_mf/broken.sh: line 3: fooBar: command not found
If this is a bash script please try:
  $ set -exv; . ProjectDIR/rt/sh_to_mf/broken.sh
See https://lmod.readthedocs.io/en/latest/260_sh_to_modulefile.html for details.
While processing the following module(s):
    Module fullname  Module Filename
    brokenSh/1.0     ProjectDIR/rt/sh_to_mf/mf/brokenSh/1.0.lua
===========================
step 18
lua ProjectDIR/src/lmod.in.lua shell --regression_testing load wrapperSh/1.0
===========================
===========================
step 19
lua ProjectDIR/src/lmod.in.lua shell --regression_testing save
===========================
Saved current collection of modules to: "default"
===========================
step 20
export LD_LIBRARY_PATH=foo
===========================
===========================
step 21
lua ProjectDIR/src/lmod.in.lua shell --regression_testing restore
===========================
Restoring modules from user's default
===========================
step 22
lua ProjectDIR/src/lmod.in.lua shell --regression_testing --mt
===========================
_ModuleTable_ = {
  MTversion = 3,
  c_rebuildTime = false,
  c_shortTime = false,
  depthT = {},
  family = {},
  mT = {
    wrapperSh = {
      fn = "ProjectDIR/rt/sh_to_mf/mf/wrapperSh/1.0.lua",
      fullName = "wrapperSh/1.0",
      loadOrder = 1,
      mcmdT = {
        ["ProjectDIR/rt/sh_to_mf/second.sh arg1"] = {
          [[setenv("SECOND","FOO_BAR")]],
        },
        ["ProjectDIR/rt/sh_to_mf/tstScript.sh"] = {
          [[append_path("LD_LIBRARY_PATH","/abc/def")]], [[append_path("LD_LIBRARY_PATH","/def/qrst")]], [[setenv("MY_NAME","tstScript.sh")]], [[setenv("PTH","ProjectDIR/rt/sh_to_mf/bin:ProjectDIR/proj_mgmt:PATH_to_TM:ProjectDIR/rt/sh_to_mf/sbin")]], [[setenv("TST_SCRIPT","1")]], [[set_alias("fooAlias","foobin -q -l")]], [=[set_shell_function("banner"," \
    local str=\"$1\";\
    local RED='\\033[1;31m';\
    local NONE='\\033[0m';\
    echo \"${RED}${str}${NONE}\"\
","")]=], [[set_shell_function("fooFunc"," \
    echo \"arg1: $1\"\
","")]], [=[set_shell_function("junk"," \
    if [ -n \"${ZSH_VERSION:-}\" ]; then\
        \\echo \"junk\";\
    fi\
","")]=], [[set_shell_function("my_help"," \
    echo \"do not forget \\\"foo\\\"\"\
","")]], [[set_shell_function("save_args"," \
    for arg in \"$@\";\
    do\
        printf \"%s\\n\" \"$arg\" | sed -e \"s/'/'\\\\\\\\''/g\" -e \"1s/^/'/\" -e \"\\$s/\\$/' \\\\\\\\/\";\
    done;\
    echo \" \"\
","")]], [[complete("bash","XyZ123","-F _xyz123")]],
        },
      },
      propT = {},
      stackDepth = 0,
      status = "active",
      userName = "wrapperSh/1.0",
      wV = "000000001.*zfinal",
    },
  },
  mpathA = {
    "ProjectDIR/rt/sh_to_mf/mf",
  },
  systemBaseMPATH = "ProjectDIR/rt/sh_to_mf/mf",
}
===========================
step 23
lua ProjectDIR/src/lmod.in.lua shell --regression_testing load conda/24.3
===========================
===========================
step 24
lua ProjectDIR/src/lmod.in.lua shell --regression_testing load A
===========================
===========================
step 25
lua ProjectDIR/src/lmod.in.lua shell --regression_testing list
===========================
Currently Loaded Modules:
  1) A/1.0
