more work on rename

git-svn-id: file:///root/webif/svn/humax/pkg/src/webif/trunk@197 2a923420-c742-0410-a762-8d5b09965624
This commit is contained in:
hummypkg
2011-06-25 20:59:50 +00:00
parent 9faac3c8fe
commit 8d67bb82bb
11 changed files with 300 additions and 54 deletions

View File

@@ -216,7 +216,7 @@ proc {epg cleanup} {} {
proc {epg exec} {mode args} {
set raw 0
set cmd [list /mod/bin/epg -f $epgpath]
set cmd [list /mod/bin/epg -f $::epgpath]
set extra ""
foreach arg $args {
if {[string first "-" $arg] == 0} {

View File

@@ -75,7 +75,14 @@ proc {ts exec} {file} {
return [exec {*}$cmd]
}
proc {ts fetch} {file} {
proc {ts fetch} {file {checked 0}} {
# Check that this is a .ts file which has at least one sidecar
# file (.nts)
if {!$checked} {
if {[file extension $file] ne ".ts"} { return 0 }
if {![file exists "[file rootname $file].nts"]} { return 0 }
}
return [ts parse $file [ts exec $file]]
}