Psst.. new poll here.
Psst.. new forums here.
Microsoft is blocking us again (TY IP Reputation!) so dont bother with any of their useless mail servers here and just use oauth login instead. Thank the nice Russians for causing that. :)
Paste
Pasted as Tcl by Luka ( 16 years ago )
proc listTree {rootdir_} {
set currentnodes [glob -nocomplain -directory $rootdir_ -type d *]
if {[llength $currentnodes] <= 0} {
# aktualny katalog jest lisciem i posiada pliki to wypisz te pliki
set fileslastnode [glob -nocomplain -directory $rootdir_ -type f *]
if {[llength $fileslastnode] > 0} {
foreach eachfile $fileslastnode {
puts "$eachfile"
}
}
return
} else {
# Rekursywnie przegladaj wszystkie katalogi
foreach node $currentnodes {
listTree $node
}
}
}
Revise this Paste
Children: 41285