Listing nach Titel sortieren
This commit is contained in:
parent
fcc1e14e04
commit
5df1180450
1 changed files with 12 additions and 6 deletions
|
@ -1,6 +1,6 @@
|
|||
#!/usr/local/bin/python
|
||||
|
||||
# $Schlepperbande: src/tivomirror/tivomirror,v 1.60 2014/07/02 09:54:33 stb Exp $
|
||||
# $Schlepperbande: src/tivomirror/tivomirror,v 1.61 2014/07/05 15:07:25 stb Exp $
|
||||
#
|
||||
# Stefans Script, um die Sendungen vom Tivo runterzuladen und in MPEG4
|
||||
# zu transkodieren.
|
||||
|
@ -422,13 +422,19 @@ def download_episode(toc, downloaddb, episode):
|
|||
def printtoc(toc, downloaddb):
|
||||
items = toc.toc.getElementsByTagName("Item")
|
||||
print "*** %d shows listed" % (items.length)
|
||||
shows = {}
|
||||
for node in items:
|
||||
item = TivoItem(node)
|
||||
reason = wantitem(item, downloaddb)
|
||||
if (reason != ""):
|
||||
print "--- %-11.11s: %s" % (reason, item.name)
|
||||
continue
|
||||
print "*** downloading %s (%.3fGB)" % (item.name, item.sourcesize / 1e9)
|
||||
if item.title not in shows:
|
||||
shows[item.title] = []
|
||||
shows[item.title].append(item)
|
||||
for title in sorted(shows):
|
||||
for item in shows[title]:
|
||||
reason = wantitem(item, downloaddb)
|
||||
if (reason != ""):
|
||||
print "%-7.7s: %s" % (reason, item.name)
|
||||
continue
|
||||
print "*** downloading %s (%.3fGB)" % (item.name, item.sourcesize / 1e9)
|
||||
|
||||
|
||||
def main():
|
||||
|
|
Loading…
Reference in a new issue