mirror of
https://github.com/envmodules/modules.git
synced 2026-06-10 00:56:30 +08:00
This is a patch by John Tseng,
It adds the ability to support Dynamic columns using stty you just setenv DYNAMIC_COLUMNS 1 and it will start using them. Kent
This commit is contained in:
@@ -18,6 +18,16 @@ set flag_default_dir 1 ;# Report default directories
|
||||
set flag_default_mf 1 ;# Report default modulefiles and version alias
|
||||
set g_def_seperator ":" ;# Default path seperator
|
||||
|
||||
# Dynamic column
|
||||
if {[info exists env(DYNAMIC_COLUMNS)]} { # do dynamic columns?
|
||||
# yes, read the stty size size information and reset DEF_COLUMNS
|
||||
set stty_output [exec stty size]
|
||||
if {$stty_output != ""} {
|
||||
set dynamic_column [lindex $stty_output 1]
|
||||
set DEF_COLUMNS $dynamic_column
|
||||
}
|
||||
}
|
||||
|
||||
# Change this to your support email address...
|
||||
set contact "root@localhost"
|
||||
|
||||
@@ -2846,7 +2856,7 @@ proc cmdModuleHelp {args} {
|
||||
}
|
||||
if {$done == 0} {
|
||||
report "Modules Release Tcl $MODULES_CURRENT_VERSION " 1
|
||||
report {($RCSfile: modulecmd.tcl,v $ $Revision: 1.120 $)}
|
||||
report {($RCSfile: modulecmd.tcl,v $ $Revision: 1.121 $)}
|
||||
report { Copyright GNU GPL v2 1991}
|
||||
report {Usage: module [ command ]}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user