usbmodeswitch: Updated to v.1.2.6 from shibby's branch.
[tomato.git] / release / src / router / usbmodeswitch / jim / initjimsh.tcl
bloba764f3a791c00bcb020b8a8c77759462baf57c1b
1 # This pseudo-package is loaded from jimsh to add additional
2 # paths to $auto_path and to source ~/.jimrc
4 proc _jimsh_init {} {
5 rename _jimsh_init {}
7 # Add to the standard auto_path
8 lappend p {*}[split [env JIMLIB {}] $::tcl_platform(pathSeparator)]
9 lappend p {*}$::auto_path
10 lappend p [file dirname [info nameofexecutable]]
11 set ::auto_path $p
13 if {$::tcl_interactive && [env HOME {}] ne ""} {
14 foreach src {.jimrc jimrc.tcl} {
15 if {[file exists [env HOME]/$src]} {
16 uplevel #0 source [env HOME]/$src
17 break
23 if {$tcl_platform(platform) eq "windows"} {
24 set jim_argv0 [string map {\\ /} $jim_argv0]
27 _jimsh_init