View Single Post
Old 01-03-2012, 05:08 AM   #1
adrian_loetscher
Junior Member
adrian_loetscher began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Dec 2011
Device: Archos 70B
Continue conversion with debug stage?

Hi. I have a question if it is possible to enter in the conversion process on a specific debug-stage (for example the input-stage)?

I would like to do this, because I have to use more than 3 search&replace criterias to get the whole table of contents from the pdf.

I thought that I would use the following steps:
  1. Convert the pdf-file to epub using only the DEBUG_PIPELINE option
  2. Then go to the input-directory in the debug-folder and edit manually the generated html-file, using for example sed.
  3. Then continue with the conversion with the files in the input-directory, withouth using the input-plugin again and enter in the conversion process on the pre-processing stage.

But I can't find such an option 3, perhaps it isn't possible? My reasons, why I would enter in the input-stage are the following:
  • I would have to use more than three replace-criterias to convert the pdf completely without manually editing.
  • I could do some finetuning on the converted ebook in Sigil, but the creation of a table of contents is difficult in Sigil and would be simpler with more than 3 search&replace criterias in Calibre.
  • I could create a zip-file of the input-directory and add this format in the "Edit Metadata" dialog in Calibre. But then I would have to do the pre-processing stage manually to format the paragraphs for example, because otherwhise I would get for each line in the original pdf a paragraph after conversion of the zip to epub. Perhaps I do something wrong, because the calibre documentation suggests this way:
    Quote:
    If you want to edit the input document a little before having calibre convert it, the best thing to do is edit the files in the input sub-directory, then zip it up, and use the zip file as the input format for subsequent conversions. To do this use the Edit meta information dialog to add the zip file as a format for the book and then, in the top left corner of the conversion dialog, select ZIP as the input format.
  • Or I could manipulate the html-file in the parsed-directory, which already is pre-processed and then zipping and importing this directory into Calibre to convert from zip to epub. But with the pre-processing some useful information gets lost to manipulate the html-file with sed.

I hope, that I could explain my problem. Thanks you for any response.

Adrian.

Last edited by adrian_loetscher; 01-03-2012 at 05:38 AM. Reason: Add an information from the calibre-documentation
adrian_loetscher is offline   Reply With Quote