From f700e055d4aab2a567e8fd710ffceef29246bcdc Mon Sep 17 00:00:00 2001 From: Xavier Delaruelle Date: Mon, 3 Sep 2018 07:01:50 +0200 Subject: [PATCH] install: add --enable-silent-shell-debug-support configure opt Add the ability to control whether or not code to support silent shell debug should be added to the module function and sh-kind initialization scripts. Enabled by default Fixes #166 --- .travis.yml | 2 +- INSTALL.rst | 4 +++ Makefile | 7 ++++ Makefile.inc.in | 2 ++ configure | 11 ++++-- init/Makefile | 6 ++++ init/bash.in | 34 +++++++++--------- init/ksh.in | 36 +++++++++---------- init/sh.in | 34 +++++++++--------- init/zsh.in | 34 +++++++++--------- modulecmd.tcl.in | 34 ++++++++++-------- site.exp.in | 1 + testsuite/install.00-init/030-options.exp | 9 +++-- testsuite/modules.70-maint/120-autoinit.exp | 39 ++++++++++++--------- 14 files changed, 148 insertions(+), 105 deletions(-) diff --git a/.travis.yml b/.travis.yml index 95a95741..8392863f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -83,7 +83,7 @@ matrix: - cmake3 - r-base-core - - env: CONFIGURE_OPTS='--with-tclsh=tclsh8.4 --prefix=/tmp/modules --enable-compat-version --enable-versioning --with-loadedmodules=null:dot --without-pager' + - env: CONFIGURE_OPTS='--with-tclsh=tclsh8.4 --prefix=/tmp/modules --enable-compat-version --enable-versioning --disable-silent-shell-debug-support --with-loadedmodules=null:dot --without-pager' EXTRA_SCRIPT_PRETEST='make install-testmodulerc install-testsiteconfig install-testmodspath-empty' EXTRA_SCRIPT_POSTTEST='make uninstall-testconfig' addons: apt: diff --git a/INSTALL.rst b/INSTALL.rst index 5500ecc6..07384282 100644 --- a/INSTALL.rst +++ b/INSTALL.rst @@ -242,6 +242,10 @@ instance ``--disable-set-manpath``): to Modules version is added to the shared modulepath and enables to switch from one Modules version to another. (default=no) +--enable-silent-shell-debug-support + Generate code in module function definition and + initialization scripts to add support for silencing + shell debugging properties (default=yes) --enable-auto-handling Set modulecmd.tcl to automatically apply automated modulefiles handling actions, like loading the diff --git a/Makefile b/Makefile index 003decda..3bf5acff 100644 --- a/Makefile +++ b/Makefile @@ -85,6 +85,12 @@ else setnotversioning := endif +ifeq ($(silentshdbgsupport),y) + setsilentshdbgsupport := +else + setsilentshdbgsupport := \# +endif + ifeq ($(autohandling),y) setautohandling := 1 else @@ -104,6 +110,7 @@ sed -e 's|@prefix@|$(prefix)|g' \ -e 's|@pager@|$(pager)|g' \ -e 's|@pageropts@|$(pageropts)|g' \ -e 's|@autohandling@|$(setautohandling)|g' \ + -e 's|@silentshdbgsupport@|$(setsilentshdbgsupport)|g' \ -e 's|@VERSIONING@|$(setversioning)|g' \ -e 's|@NOTVERSIONING@|$(setnotversioning)|g' \ -e 's|@MODULES_RELEASE@|$(MODULES_RELEASE)|g' \ diff --git a/Makefile.inc.in b/Makefile.inc.in index 6c8e71a7..d3210add 100644 --- a/Makefile.inc.in +++ b/Makefile.inc.in @@ -23,6 +23,8 @@ VERSION := @VERSION@ modulepath := @modulepath@ loadedmodules := @loadedmodules@ +# silent shell debug support +silentshdbgsupport := @silentshdbgsupport@ # runtime quarantine mechanism quarantinevars := @quarantinevars@ diff --git a/configure b/configure index e8f433b0..ccaa0a9c 100755 --- a/configure +++ b/configure @@ -30,8 +30,8 @@ arglist="TCLSH SPHINXBUILD PS BASENAME RMDIR_IGN_NON_EMPTY VERSION \ baseprefix prefix bindir libexecdir etcdir initdir datarootdir mandir docdir \ modulefilesdir setmanpath appendmanpath setbinpath appendbinpath \ setdotmodulespath docinstall examplemodulefiles builddoc gitworktree \ -usemanpath compatversion EXEEXT versioning autohandling pager pageropts \ -modulepath loadedmodules quarantinevars" +usemanpath compatversion EXEEXT versioning silentshdbgsupport autohandling \ +pager pageropts modulepath loadedmodules quarantinevars" compatarglist= # flags to know if argument has been specified on command-line @@ -51,6 +51,7 @@ examplemodulefiles=y compatversion=y EXEEXT= versioning=n +silentshdbgsupport=y autohandling=n loadedmodules= quarantinevars= @@ -147,6 +148,10 @@ Optional Features: versioning enabled Modules installation, containing modulefiles that enable to switch from one Modules version to another [no] + --enable-silent-shell-debug-support + generate code in module function definition and + initialization scripts to add support for silencing + shell debugging properties [yes] --enable-auto-handling set modulecmd.tcl to automatically apply automated modulefiles handling actions, like loading the pre-requisites of a modulefile when loading this @@ -309,6 +314,8 @@ for arg in "$@"; do defcompatversion=0 ;; --enable-versioning*|--disable-versioning) versioning=$(get_feature_value "$arg") ;; + --enable-silent-shell-debug-support*|--disable-silent-shell-debug-support) + silentshdbgsupport=$(get_feature_value "$arg") ;; --enable-auto-handling*|--disable-auto-handling) autohandling=$(get_feature_value "$arg") ;; --with-bin-search-path=*|--without-bin-search-path) diff --git a/init/Makefile b/init/Makefile index 6ca1d8e9..2be0f366 100644 --- a/init/Makefile +++ b/init/Makefile @@ -88,6 +88,11 @@ else usemanpathre := /@usemanpath@/d notusemanpathre := s|@notusemanpath@||g endif +ifeq ($(silentshdbgsupport),y) + silentshdbgsupportre := s|@silentshdbgsupport@||g +else + silentshdbgsupportre := /@silentshdbgsupport@/d +endif # comment entries if feature not enabled ifeq ($(versioning),y) @@ -131,6 +136,7 @@ sed -e 's|@prefix@|$(prefix)|g' \ -e '$(prependbinpathre)' \ -e '$(compatversionre)' \ -e '$(notcompatversionre)' \ + -e '$(silentshdbgsupportre)' \ -e '$(usemanpathre)' \ -e '$(notusemanpathre)' \ -e $$'s|@modulerc@|$(modulerc)|g' \ diff --git a/init/bash.in b/init/bash.in index e249318e..492b3041 100644 --- a/init/bash.in +++ b/init/bash.in @@ -1,15 +1,15 @@ -unset _mlshdbg; -# disable shell debugging for the run of this init file -if [ "${MODULES_SILENT_SHELL_DEBUG:-0}" = '1' ]; then - # immediately disable debugging to echo the less number of line possible - case "$-" in - *v*x*) set +vx; _mlshdbg='vx' ;; - *v*) set +v; _mlshdbg='v' ;; - *x*) set +x; _mlshdbg='x' ;; - *) _mlshdbg='' ;; - esac; -fi; - +@silentshdbgsupport@unset _mlshdbg; +@silentshdbgsupport@# disable shell debugging for the run of this init file +@silentshdbgsupport@if [ "${MODULES_SILENT_SHELL_DEBUG:-0}" = '1' ]; then +@silentshdbgsupport@ # immediately disable debugging to echo the less number of line possible +@silentshdbgsupport@ case "$-" in +@silentshdbgsupport@ *v*x*) set +vx; _mlshdbg='vx' ;; +@silentshdbgsupport@ *v*) set +v; _mlshdbg='v' ;; +@silentshdbgsupport@ *x*) set +x; _mlshdbg='x' ;; +@silentshdbgsupport@ *) _mlshdbg='' ;; +@silentshdbgsupport@ esac; +@silentshdbgsupport@fi; +@silentshdbgsupport@ # define modules runtine quarantine configuration @setquarvars@export MODULES_RUN_QUARANTINE='@RUN_QUARANTINE@' @setquarvars@@export RUNENV_VAR='RUNENV_VAL'@ @@ -114,8 +114,8 @@ fi @setmanpath@@appendmanpath@ MANPATH=$manpath${manpath:+:}@mandir@; export MANPATH @setmanpath@fi @setmanpath@ -# restore shell debugging options if disabled -if [ -n "${_mlshdbg:-}" ]; then - set -$_mlshdbg; - unset _mlshdbg; -fi; +@silentshdbgsupport@# restore shell debugging options if disabled +@silentshdbgsupport@if [ -n "${_mlshdbg:-}" ]; then +@silentshdbgsupport@ set -$_mlshdbg; +@silentshdbgsupport@ unset _mlshdbg; +@silentshdbgsupport@fi; diff --git a/init/ksh.in b/init/ksh.in index e375d40b..e8f6cb9a 100644 --- a/init/ksh.in +++ b/init/ksh.in @@ -1,15 +1,15 @@ -unset _mlshdbg; -# disable shell debugging for the run of this init file -if [ "${MODULES_SILENT_SHELL_DEBUG:-0}" = '1' ]; then - # immediately disable debugging to echo the less number of line possible - case "$-" in - *v*x*) set +vx; _mlshdbg='vx' ;; - *v*) set +v; _mlshdbg='v' ;; - *x*) set +x; _mlshdbg='x' ;; - *) _mlshdbg='' ;; - esac; -fi; - +@silentshdbgsupport@unset _mlshdbg; +@silentshdbgsupport@# disable shell debugging for the run of this init file +@silentshdbgsupport@if [ "${MODULES_SILENT_SHELL_DEBUG:-0}" = '1' ]; then +@silentshdbgsupport@ # immediately disable debugging to echo the less number of line possible +@silentshdbgsupport@ case "$-" in +@silentshdbgsupport@ *v*x*) set +vx; _mlshdbg='vx' ;; +@silentshdbgsupport@ *v*) set +v; _mlshdbg='v' ;; +@silentshdbgsupport@ *x*) set +x; _mlshdbg='x' ;; +@silentshdbgsupport@ *) _mlshdbg='' ;; +@silentshdbgsupport@ esac; +@silentshdbgsupport@fi; +@silentshdbgsupport@ # define modules runtine quarantine configuration @setquarvars@export MODULES_RUN_QUARANTINE='@RUN_QUARANTINE@' @setquarvars@@export RUNENV_VAR='RUNENV_VAL'@ @@ -112,9 +112,9 @@ fi @setmanpath@fi @setmanpath@ unset _mlinstr - -# restore shell debugging options if disabled -if [ -n "${_mlshdbg:-}" ]; then - set -$_mlshdbg; - unset _mlshdbg; -fi; +@silentshdbgsupport@ +@silentshdbgsupport@# restore shell debugging options if disabled +@silentshdbgsupport@if [ -n "${_mlshdbg:-}" ]; then +@silentshdbgsupport@ set -$_mlshdbg; +@silentshdbgsupport@ unset _mlshdbg; +@silentshdbgsupport@fi; diff --git a/init/sh.in b/init/sh.in index 6793f4f3..5e0eaefd 100644 --- a/init/sh.in +++ b/init/sh.in @@ -1,15 +1,15 @@ -unset _mlshdbg; -# disable shell debugging for the run of this init file -if [ "${MODULES_SILENT_SHELL_DEBUG:-0}" = '1' ]; then - # immediately disable debugging to echo the less number of line possible - case "$-" in - *v*x*) set +vx; _mlshdbg='vx' ;; - *v*) set +v; _mlshdbg='v' ;; - *x*) set +x; _mlshdbg='x' ;; - *) _mlshdbg='' ;; - esac; -fi; - +@silentshdbgsupport@unset _mlshdbg; +@silentshdbgsupport@# disable shell debugging for the run of this init file +@silentshdbgsupport@if [ "${MODULES_SILENT_SHELL_DEBUG:-0}" = '1' ]; then +@silentshdbgsupport@ # immediately disable debugging to echo the less number of line possible +@silentshdbgsupport@ case "$-" in +@silentshdbgsupport@ *v*x*) set +vx; _mlshdbg='vx' ;; +@silentshdbgsupport@ *v*) set +v; _mlshdbg='v' ;; +@silentshdbgsupport@ *x*) set +x; _mlshdbg='x' ;; +@silentshdbgsupport@ *) _mlshdbg='' ;; +@silentshdbgsupport@ esac; +@silentshdbgsupport@fi; +@silentshdbgsupport@ # define modules runtine quarantine configuration @setquarvars@export MODULES_RUN_QUARANTINE='@RUN_QUARANTINE@' @setquarvars@@export RUNENV_VAR='RUNENV_VAL'@ @@ -114,8 +114,8 @@ BASH_ENV=@initdir@/bash; export BASH_ENV @setmanpath@@appendmanpath@ *) MANPATH=$manpath${manpath:+:}@mandir@; export MANPATH @setmanpath@esac @setmanpath@ -# restore shell debugging options if disabled -if [ -n "${_mlshdbg:-}" ]; then - set -$_mlshdbg; - unset _mlshdbg; -fi; +@silentshdbgsupport@# restore shell debugging options if disabled +@silentshdbgsupport@if [ -n "${_mlshdbg:-}" ]; then +@silentshdbgsupport@ set -$_mlshdbg; +@silentshdbgsupport@ unset _mlshdbg; +@silentshdbgsupport@fi; diff --git a/init/zsh.in b/init/zsh.in index 0860779a..12caabf1 100644 --- a/init/zsh.in +++ b/init/zsh.in @@ -1,15 +1,15 @@ -unset _mlshdbg; -# disable shell debugging for the run of this init file -if [ "${MODULES_SILENT_SHELL_DEBUG:-0}" = '1' ]; then - # immediately disable debugging to echo the less number of line possible - case "$-" in - *v*x*) set +vx; _mlshdbg='vx' ;; - *v*) set +v; _mlshdbg='v' ;; - *x*) set +x; _mlshdbg='x' ;; - *) _mlshdbg='' ;; - esac; -fi; - +@silentshdbgsupport@unset _mlshdbg; +@silentshdbgsupport@# disable shell debugging for the run of this init file +@silentshdbgsupport@if [ "${MODULES_SILENT_SHELL_DEBUG:-0}" = '1' ]; then +@silentshdbgsupport@ # immediately disable debugging to echo the less number of line possible +@silentshdbgsupport@ case "$-" in +@silentshdbgsupport@ *v*x*) set +vx; _mlshdbg='vx' ;; +@silentshdbgsupport@ *v*) set +v; _mlshdbg='v' ;; +@silentshdbgsupport@ *x*) set +x; _mlshdbg='x' ;; +@silentshdbgsupport@ *) _mlshdbg='' ;; +@silentshdbgsupport@ esac; +@silentshdbgsupport@fi; +@silentshdbgsupport@ # define modules runtine quarantine configuration @setquarvars@export MODULES_RUN_QUARANTINE='@RUN_QUARANTINE@' @setquarvars@@export RUNENV_VAR='RUNENV_VAL'@ @@ -111,8 +111,8 @@ fi @setmanpath@@appendmanpath@ MANPATH=$manpath${manpath:+:}@mandir@; export MANPATH @setmanpath@fi @setmanpath@ -# restore shell debugging options if disabled -if [ -n "${_mlshdbg:-}" ]; then - set -$_mlshdbg; - unset _mlshdbg; -fi; +@silentshdbgsupport@# restore shell debugging options if disabled +@silentshdbgsupport@if [ -n "${_mlshdbg:-}" ]; then +@silentshdbgsupport@ set -$_mlshdbg; +@silentshdbgsupport@ unset _mlshdbg; +@silentshdbgsupport@fi; diff --git a/modulecmd.tcl.in b/modulecmd.tcl.in index 75deb353..a871c7c5 100644 --- a/modulecmd.tcl.in +++ b/modulecmd.tcl.in @@ -4335,16 +4335,18 @@ if ( ! \$?histchars && ! \$?prompt ) alias module '$eval_cmd' ;" # an empty runtime variable is set even if no corresponding # MODULES_RUNENV_* variable found, as var cannot be unset on # modified environment command-line - set fdef "${fname}() { - unset _mlshdbg; - if \[ \"\$\{MODULES_SILENT_SHELL_DEBUG:-0\}\" = '1' \]; then - case \"$-\" in - *v*x*) set +vx; _mlshdbg='vx' ;; - *v*) set +v; _mlshdbg='v' ;; - *x*) set +x; _mlshdbg='x' ;; - *) _mlshdbg='' ;; - esac; - fi; + set fdef "${fname}() {" +@silentshdbgsupport@ append fdef { +@silentshdbgsupport@ unset _mlshdbg; +@silentshdbgsupport@ if [ "${MODULES_SILENT_SHELL_DEBUG:-0}" = '1' ]; then +@silentshdbgsupport@ case "$-" in +@silentshdbgsupport@ *v*x*) set +vx; _mlshdbg='vx' ;; +@silentshdbgsupport@ *v*) set +v; _mlshdbg='v' ;; +@silentshdbgsupport@ *x*) set +x; _mlshdbg='x' ;; +@silentshdbgsupport@ *) _mlshdbg='' ;; +@silentshdbgsupport@ esac; +@silentshdbgsupport@ fi;} + append fdef " unset _mlre _mlIFS; if \[ -n \"\${IFS+x}\" \]; then _mlIFS=\$IFS; @@ -4372,11 +4374,13 @@ $::g_shell '\"\$@\"'`; else unset IFS; fi; - unset _mlre _mlv _mlrv _mlIFS; - if [ -n "${_mlshdbg:-}" ]; then - set -$_mlshdbg; - fi; - unset _mlshdbg; + unset _mlre _mlv _mlrv _mlIFS;} +@silentshdbgsupport@ append fdef { +@silentshdbgsupport@ if [ -n "${_mlshdbg:-}" ]; then +@silentshdbgsupport@ set -$_mlshdbg; +@silentshdbgsupport@ fi; +@silentshdbgsupport@ unset _mlshdbg;} + append fdef { return $_mlstatus;} append fdef "\n};" if {[isStderrTty]} { diff --git a/site.exp.in b/site.exp.in index 662e350b..1ae2434a 100644 --- a/site.exp.in +++ b/site.exp.in @@ -14,6 +14,7 @@ set install_version "@VERSION@" set install_modulepath {@modulepath@} set install_loadedmodules "@loadedmodules@" +set install_silentshdbgsupport "@silentshdbgsupport@" set install_quarantinevars "@quarantinevars@" set install_compatversion "@compatversion@" diff --git a/testsuite/install.00-init/030-options.exp b/testsuite/install.00-init/030-options.exp index b84523eb..3ff308e4 100644 --- a/testsuite/install.00-init/030-options.exp +++ b/testsuite/install.00-init/030-options.exp @@ -225,6 +225,7 @@ if {$install_loadedmodules ne ""} { # basic test for MODULES_SILENT_SHELL_DEBUG, checking module answer is still present # among the debugging output +if {$install_silentshdbgsupport eq y} { if {$verbose > 0} { send_user "\tChecking MODULES_SILENT_SHELL_DEBUG\n" send_user "\tSetup MODULES_SILENT_SHELL_DEBUG = '1'\n" @@ -268,12 +269,16 @@ foreach shell $shell_sh_family { } } +unset env(MODULES_SILENT_SHELL_DEBUG) +} elseif {$verbose > 0} { + send_user "\tSkipping silent shell debug checks\n" +} + + # # Clean up variables used in this test case # -unset env(MODULES_SILENT_SHELL_DEBUG) - unset bad_cmd unset use_desc unset mod_examples diff --git a/testsuite/modules.70-maint/120-autoinit.exp b/testsuite/modules.70-maint/120-autoinit.exp index f7657e74..79efb9cb 100644 --- a/testsuite/modules.70-maint/120-autoinit.exp +++ b/testsuite/modules.70-maint/120-autoinit.exp @@ -103,17 +103,8 @@ set func_quar_zsh "\\s*unset _mlre _mlIFS; \\s*IFS=' '; \\s*for _mlv in \\\${=MODULES_RUN_QUARANTINE:-}; do $end_quar_sh" -set func_clean_ifs "\\s*if \\\[ -n \"\\\${_mlIFS\\\+x}\" \\\]; then -\\s*IFS=\\\$_mlIFS; -\\s*else -\\s*unset IFS; -\\s*fi; -\\s*unset _mlre _mlv _mlrv _mlIFS; -\\s*if \\\[ -n \"\\\${_mlshdbg:-}\" \\\]; then -\\s*set -\\\$_mlshdbg; -\\s*fi; -\\s*unset _mlshdbg; -\\s*return \\\$_mlstatus;" + +if {$install_silentshdbgsupport eq y} { set func_silentdbg "\\s*unset _mlshdbg; \\s*if \\\[ \"\\\${MODULES_SILENT_SHELL_DEBUG:-0}\" = '1' \\\]; then \\s*case \"\\\$-\" in @@ -122,7 +113,23 @@ set func_silentdbg "\\s*unset _mlshdbg; \\s*\\\*x\\\*\\\) set \\\+x; _mlshdbg='x' ;; \\s*\\\*\\\) _mlshdbg='' ;; \\s*esac; -\\s*fi;" +\\s*fi;\n" +set end_silentdbg "\\s*if \\\[ -n \"\\\${_mlshdbg:-}\" \\\]; then +\\s*set -\\\$_mlshdbg; +\\s*fi; +\\s*unset _mlshdbg;\n" +} else { +set func_silentdbg "" +set end_silentdbg "" +} + +set func_clean_ifs "\\s*if \\\[ -n \"\\\${_mlIFS\\\+x}\" \\\]; then +\\s*IFS=\\\$_mlIFS; +\\s*else +\\s*unset IFS; +\\s*fi; +\\s*unset _mlre _mlv _mlrv _mlIFS; +$end_silentdbg\\s*return \\\$_mlstatus;" set func_modcmd_sh "\\s*if \\\[ -n \"\\\${_mlre:-}\" \\\]; then \\s*eval `eval \\\${_mlre}$install_tclsh $modulecmd_pathre sh '\"\\$\\@\"'`; @@ -156,10 +163,10 @@ if {$is_stderr_tty} { set add_func_fish "" } -set func_sh "$func_name\\\(\\\) {\n$func_silentdbg\n$func_quar_sh\n$func_modcmd_sh\n\\s*_mlstatus=\\\$\\\?;\n$func_clean_ifs\n};$add_func_sh" -set func_bash "$func_name\\\(\\\) {\n$func_silentdbg\n$func_quar_sh\n$func_modcmd_bash\n\\s*_mlstatus=\\\$\\\?;\n$func_clean_ifs\n};$add_func_sh" -set func_ksh "$func_name\\\(\\\) {\n$func_silentdbg\n$func_quar_sh\n$func_modcmd_ksh\n\\s*_mlstatus=\\\$\\\?;\n$func_clean_ifs\n};$add_func_sh" -set func_zsh "$func_name\\\(\\\) {\n$func_silentdbg\n$func_quar_zsh\n$func_modcmd_zsh\n\\s*_mlstatus=\\\$\\\?;\n$func_clean_ifs\n};$add_func_sh" +set func_sh "$func_name\\\(\\\) {\n$func_silentdbg$func_quar_sh\n$func_modcmd_sh\n\\s*_mlstatus=\\\$\\\?;\n$func_clean_ifs\n};$add_func_sh" +set func_bash "$func_name\\\(\\\) {\n$func_silentdbg$func_quar_sh\n$func_modcmd_bash\n\\s*_mlstatus=\\\$\\\?;\n$func_clean_ifs\n};$add_func_sh" +set func_ksh "$func_name\\\(\\\) {\n$func_silentdbg$func_quar_sh\n$func_modcmd_ksh\n\\s*_mlstatus=\\\$\\\?;\n$func_clean_ifs\n};$add_func_sh" +set func_zsh "$func_name\\\(\\\) {\n$func_silentdbg$func_quar_zsh\n$func_modcmd_zsh\n\\s*_mlstatus=\\\$\\\?;\n$func_clean_ifs\n};$add_func_sh" set func_csh "if \\\( \\\$\\\?histchars && \\\$\\\?prompt \\\) alias module 'set _histchars = \\\$histchars; unset histchars; set _prompt=\"\\\$prompt\"; set prompt=\"\"; eval \"`$install_tclsh $modulecmd_pathre csh \\\\!\\*:q`\"; set _exit=\"\\\$status\"; set histchars = \\\$_histchars; unset _histchars; set prompt=\"\\\$_prompt\"; unset _prompt; test 0 = \\\$_exit' ; if \\\( \\\$\\\?histchars && \\\! \\\$\\\?prompt \\\) alias module 'set _histchars = \\\$histchars; unset histchars; eval \"`$install_tclsh $modulecmd_pathre csh \\\\!\\*:q`\"; set _exit=\"\\\$status\"; set histchars = \\\$_histchars; unset _histchars; test 0 = \\\$_exit' ; if \\\( \\\! \\\$\\\?histchars && \\\$\\\?prompt \\\) alias module 'set _prompt=\"\\\$prompt\"; set prompt=\"\"; eval \"`$install_tclsh $modulecmd_pathre csh \\\\!\\*:q`\"; set _exit=\"\\\$status\"; set prompt=\"\\\$_prompt\"; unset _prompt; test 0 = \\\$_exit' ;