home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC World 1998 October
/
PCWorld_1998-10_cd.bin
/
software
/
prehled
/
komix
/
DATA.Z
/
importitfe.tcl
< prev
next >
Wrap
Text File
|
1997-11-04
|
1KB
|
62 lines
#---------------------------------------------------------------------------
#
# (c) Cayenne Software Inc. 1997
#
# File: @(#)importitfe.tcl /main/titanic/1
# Description: import tool front end
#
#---------------------------------------------------------------------------
# SccsId = @(#)importitfe.tcl /main/titanic/1 4 Nov 1997 Copyright 1997 Cayenne Software Inc.
global SCCS_W; set SCCS_W "
@(#)importitfe.tcl /main/titanic/1
"
global progName; set progName "importitfe.tcl"
proc setProg {} {
set name [string trim $SCCS_W "\n%"]
if {$name != "W"} {
regexp "@.#.(.*)\t" $name dummy name
global progName
set progName $name
}
}
proc main {argv} {
#
# tmpFile
# 1: filename1
# 2: filename1
# ...
#
setProg
set tmpFile [lvarpop argv]
if {[catch {set fd [open $tmpFile r]} msg]} {
puts stderr "ERROR\[$progName]: $msg"
catch {BasicFS::removeFile $tmpFile}
return
}
set fileNames {}
while {[gets $fd line] > 0} {
lappend fileNames $line
}
close $fd
if {[catch {BasicFS::removeFile $tmpFile} msg]} {
puts stderr "ERROR\[$progName]: $msg"
}
foreach file $fileNames {
if {[catch {
source [join $file]
} reason]} {
puts stderr "ERROR\[$progName]: $reason"
}
}
}
if {[catch {main $argv} reason]} {
puts stderr $errorInfo
}