I have code that is like this:
...
proc myProc {first last} {
for { set i $first } { $i <= $last } { incr i } {
set i_cur "PlainText$i"
<command> [glob ./../myDir/${i_cur}*]
}
}
When I run this, any file that has nothing after the number will run fine. But if there is something after the number then it doesn't.
For example, I have the valid files named PlainText0.txt
, PlainText00.txt
, and PlainText1_Plaintext.txt
. The first two work and PlainText1_Plaintext.txt
doesn't.
Basically, I do not think I am using a glob/wildcard correctly, but don't know how.