mirror of
https://bitbucket.org/svk28/rac-gui
synced 2024-11-11 00:16:53 +00:00
45 lines
1.1 KiB
Tcl
45 lines
1.1 KiB
Tcl
|
#!/bin/sh
|
||
|
# Tcl ignores the next line -*- tcl -*- \
|
||
|
exec wish "$0" -- "$@"
|
||
|
|
||
|
######################################################
|
||
|
# Rac GUI
|
||
|
# Distributed under GNU Public License
|
||
|
# Author: Sergey Kalinin svk@nuk-svk.ru
|
||
|
# Home page: https://bitbucket.org/svk28/rac-gui
|
||
|
######################################################
|
||
|
|
||
|
source [file join [pwd] rac_gui.cfg]
|
||
|
source [file join [pwd] 1c_srv.cfg]
|
||
|
|
||
|
set dir(root) [pwd]
|
||
|
|
||
|
set dir(msg) "[file join $dir(root) msgs]"
|
||
|
set dir(lib) "[file join $dir(root) lib]"
|
||
|
|
||
|
## SETTINGS ENVIRONMENT LANGUAGE ##
|
||
|
if [info exists env(LANG)] {
|
||
|
set locale $env(LANG)
|
||
|
} else {
|
||
|
set locale $locale
|
||
|
}
|
||
|
|
||
|
::msgcat::mclocale $locale
|
||
|
::msgcat::mcload $dir(msg)
|
||
|
|
||
|
## LOAD FILE ##
|
||
|
# Load modules but maain.tcl must last loaded
|
||
|
foreach modFile [lsort [glob -nocomplain [file join $dir(lib) *.tcl]]] {
|
||
|
if {[file tail $modFile] ne "gui.tcl"} {
|
||
|
source $modFile
|
||
|
puts "Loaded module $modFile"
|
||
|
}
|
||
|
}
|
||
|
source [file join $dir(lib) gui.tcl]
|
||
|
|
||
|
puts "$rac_cmd $dir(lib)"
|
||
|
.frm_tree.tree insert {} end -id "$host" -text "$host" -values "$host"
|
||
|
|
||
|
RunCommand $host "cluster list $host $port"
|
||
|
|