예제 #1
0
from mangle.book import Book
import mangle.cbz
import mangle.image

#log.basicConfig(level='DEBUG')

try:
    opts, args = getopt.getopt(sys.argv[1:], 'd:t:o:e:x')
except getopt.GetoptError, err:
    print str(err)
    sys.exit(2)

directory = '.'
extension = 'zip'
book = Book()
book.device = 'Kindle 5'
book.outputFormat = 'CBZ only'
book.title = 'Unknown'
book.overwrite = False
book.imageFlags = (mangle.image.ImageFlags.Orient
                   | mangle.image.ImageFlags.Resize)

for o, a in opts:
    if o == '-d':
        directory = a
    elif o == '-t':
        book.title = a
    elif o == '-o':
        book.outputFormat = a
    elif o == '-e':
예제 #2
0
from mangle.book import Book
import mangle.cbz
import mangle.image

#log.basicConfig(level='DEBUG')

try:
    opts, args = getopt.getopt(sys.argv[1:], 'd:t:o:e:x')
except getopt.GetoptError, err:
    print str(err)
    sys.exit(2)

directory = '.'
extension = 'zip'
book = Book()
book.device = 'Kindle 5'
book.outputFormat = 'CBZ only'
book.title = 'Unknown'
book.overwrite = False
book.imageFlags = (mangle.image.ImageFlags.Orient |
                   mangle.image.ImageFlags.Resize)


for o, a in opts:
    if o == '-d':
        directory = a
    elif o == '-t':
        book.title = a
    elif o == '-o':
        book.outputFormat = a