Wednesday, April 17, 2013

Tcl version script

Playing around with tcl and encountering some issues on a cisco router, I built this tcl script that display some locale env and information.

#!/usr/bin/tclsh
#
#

#  tcl dislay script 
#
puts " "
set sec [ clock seconds ]
#
puts "Time: [clock format $sec -format %r]"
#
puts " "
#
puts "************************************************"
puts " The Script path/name    ===> $argv0 "
puts " CmdLine arguments sets  ===> $argc "
puts " Executed  by the user   ===> $tcl_platform(user)"
puts ""
puts "*************************************************"
puts " Tickle Version $tcl_version OS $tcl_platform(os)  $tcl_platform(osVersion) and Machine $tcl_platform(machine) Platform $tcl_platform(platform) "
info patchlevel
puts " "
puts " "
puts "**************************************************"
puts  "The  Tickle Package Path  Information:"
puts ""
puts  $tcl_pkgPath"
puts ""
puts "**************************************************"
puts " "
puts $auto_path
puts " "
package require dns
package names
puts ""
puts " ^     ^"
puts "( @ . @ )"
puts "    o  "



Just playing around with Tcl, working on how to display all supported packages and hopefully display them along with the pkg version#.

Stay tune


Ken Felix
freelance Netowork/Security Engineer
kfelix/at/hyperfeed /dot/ com

No comments:

Post a Comment