From a401ab3a57b3077418323e3b57b45bfbc6913c34 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Thu, 3 Dec 2009 22:27:06 -0700 Subject: [PATCH] Fix #4084 (calibredb list stanza output should url encode the urls) --- src/calibre/library/cli.py | 3 +-- src/calibre/manual/faq.rst | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/calibre/library/cli.py b/src/calibre/library/cli.py index 50f0c6d48a..22f0542879 100644 --- a/src/calibre/library/cli.py +++ b/src/calibre/library/cli.py @@ -9,6 +9,7 @@ Command line interface to the calibre database. import sys, os, cStringIO from textwrap import TextWrapper +from urllib import quote from calibre import terminal_controller, preferred_encoding, prints from calibre.utils.config import OptionParser, prefs @@ -187,8 +188,6 @@ def do_list(db, fields, sort_by, ascending, search_text, line_width, separator, template = MarkupTemplate(XML_TEMPLATE) return template.generate(data=data, os=os).render('xml') elif output_format == 'stanza': - def quote(raw): - return raw.replace('"', r'\"') data = [i for i in data if i.has_key('fmt_epub')] for x in data: if isinstance(x['fmt_epub'], unicode): diff --git a/src/calibre/manual/faq.rst b/src/calibre/manual/faq.rst index 75becf7e17..13091df61c 100644 --- a/src/calibre/manual/faq.rst +++ b/src/calibre/manual/faq.rst @@ -196,7 +196,7 @@ When you first run |app|, it will ask you for a folder in which to store your bo Why doesn't |app| let me store books in my own directory structure? ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -The whole point of |app|'s library management features is that they provide an interface for locating books that is *much* more efficient than any possible directory scheme you could come up with for your collection. Indeed, once you become comfortable using |app|'s interface to find, sort and browse your collection, you wont ever feel the need to hunt through the files on your disk to find a book again. By managing books in its own directory struture of Author -> Title -> Book files, |app| is able to achieve a high level of reliability and standardization. +The whole point of |app|'s library management features is that they provide a search and sort based interface for locating books that is *much* more efficient than any possible directory scheme you could come up with for your collection. Indeed, once you become comfortable using |app|'s interface to find, sort and browse your collection, you wont ever feel the need to hunt through the files on your disk to find a book again. By managing books in its own directory struture of Author -> Title -> Book files, |app| is able to achieve a high level of reliability and standardization. Why doesn't |app| have a column for foo? ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~