![]() |
#1 |
Junior Member
![]() Posts: 7
Karma: 10
Join Date: Sep 2014
Device: Personal Computer
|
Keeping file name when converting
Hi all!
I have 300 epubs. I want to convert them to PDF and save them. When I save them, they have changed the file name, for example: Original Epub Name: Absolución de Luis Landero r1.0.epub PDF saved file name: Absolución - Luis Leandro.pdf How can I have my PDF saved file with the same file name as original epub file? Like that: Original Epub Name: Absolución de Luis Landero r1.0.epub PDF saved file name: Absolución de Luis Landero r1.0.pdf Thank you guys! |
![]() |
![]() |
![]() |
#2 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
The name change happened when you imported the EPUB to calibre. You will need to add the appropriate metadata to calibre, probably in a custom column. (I have a custom column "Original Filename".) Then configure the appropriate save template in Preferences ==> Saving to disk.
You can also convert via the command-line interface to avoid calibre's library naming schemes. |
![]() |
![]() |
![]() |
#3 | |
Junior Member
![]() Posts: 7
Karma: 10
Join Date: Sep 2014
Device: Personal Computer
|
Quote:
First of all thank you a lot for your answer. I am very interesting in that "Original Filename" custom column u said. How can I make it? Thank you. Greets. |
|
![]() |
![]() |
![]() |
#4 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Under Preferences, you can Add Your Own Columns.
Give it a column heading, say "Original Filename", a lookup name like "#origfile", and choose text as the type. After creating it you will need to restart calibre, and then you will have a new column for storing this info in. |
![]() |
![]() |
![]() |
#5 | |
Junior Member
![]() Posts: 7
Karma: 10
Join Date: Sep 2014
Device: Personal Computer
|
Quote:
If I understood u, I have to put the original filename of every ebook the custom column in Calibre before save it, is it? |
|
![]() |
![]() |
![]() |
#6 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
|
![]() |
![]() |
![]() |
#7 | |
Junior Member
![]() Posts: 7
Karma: 10
Join Date: Sep 2014
Device: Personal Computer
|
Quote:
But I wonder if there's any way to do it with a bunch of ebooks at the same time, I mean not editting every epub file one by one. Is it possible? |
|
![]() |
![]() |
![]() |
#8 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
It could probably be scripted via the command-line but I've never really put thought into it.
You can set the Preferences for Adding Books to read metadata from the filename via a custom regex, but then metadata will not be addded from the file contents. |
![]() |
![]() |
![]() |
#9 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Regarding your PM...
Assuming you do not need the books in the library GUI, you can use the following batch file to search the current folder (the folder you stick the batch file in) and convert all EPUBs to PDF: Code:
del conversion.log for /r %%I in ("*.epub) do ( echo ******************************* >> conversion.log echo Converting "%~dpnI.epub" to PDF >> conversion.log ebook-convert "%~dpnI.epub" "%~dpnI.pdf" >> conversion.log ) You can duplicate the effects of anything in the calibre conversion dialog using the command-line options detailed here: http://manual.calibre-ebook.com/gene...k-convert.html Change Code:
ebook-convert "%~dpnI.epub" "%~dpnI.pdf" >> conversion.log Code:
ebook-convert "%~dpnI.epub" "%~dpnI.pdf" [options go here] >> conversion.log |
![]() |
![]() |
![]() |
#10 | |
Junior Member
![]() Posts: 7
Karma: 10
Join Date: Sep 2014
Device: Personal Computer
|
Quote:
I also tried to change all these ************* for the folder where they are, but nothing happens: it opens and closes automatically. Sorry for my bad skills :/ Sin título.png |
|
![]() |
![]() |
![]() |
#11 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Quote:
![]() I forgot that the percent symbol needs to be doubled when used in windows scripts instead of the command prompt. (linux does not use two different forms.) Use this: Code:
del conversion.log for /r %%I in ("*.epub") do ( echo ******************************* >> conversion.log echo Converting "%%~dpnI.epub" to PDF >> conversion.log ebook-convert "%%~dpnI.epub" "%%~dpnI.pdf" >> conversion.log ) Code:
ebook-convert "%%~dpnI.epub" "%%~dpnI.pdf" >> conversion.log Code:
ebook-convert "%%~dpnI.epub" "%%~dpnI.pdf" [options go here] >> conversion.log Moral of the story -- my bad skills are nearly as bad as your bad skills, but worse because I don't realize it. ![]() P.S. Leave in the ************* it is there to separate the conversion logs for each other. It is plain text to be written to the file. (The "echo" command prints text out.) On second thought -- it doesn't really matter, I only stuck it there in the first place in order to record what was getting done. Just in case it ever becme important -- for instance, if you wanted to see what settings were used and print out potential errors and stuff. Just like Job Details in the calibre library window. |
![]() |
![]() |
![]() |
#12 | |
Junior Member
![]() Posts: 7
Karma: 10
Join Date: Sep 2014
Device: Personal Computer
|
Quote:
![]() Thank you so much for your time. I thought it was something impossible to do. Thank you!!!!!!!!! |
|
![]() |
![]() |
![]() |
#13 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
You're welcome.
![]() I got an opportunity to brush up on Windows batch scripting, which was fun. ![]() |
![]() |
![]() |
![]() |
#14 |
null operator (he/him)
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 21,724
Karma: 29711016
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
This thread got moved from the Recipes Sub Forum
I thought it worthy of a bump to bring it to the attention of those who don't lurk in Recipes Thanks to theducks ![]() BR Last edited by BetterRed; 09-13-2014 at 09:19 PM. |
![]() |
![]() |
![]() |
#15 |
Junior Member
![]() Posts: 7
Karma: 10
Join Date: Sep 2014
Device: Personal Computer
|
|
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Keeping Same File Names | zobop | Library Management | 3 | 06-28-2012 07:50 AM |
Keeping small caps when converting from sigil to calibre | sly_skittle | Sigil | 8 | 03-22-2012 05:59 PM |
Mac user needs help converting pdf's (TV Scripts) and keeping format!! | mcforman | Kindle Developer's Corner | 12 | 06-20-2011 05:28 PM |
Having a very hard time converting a comic and keeping it in order! | branchedout | Reading and Management | 2 | 08-18-2010 11:13 AM |
Question: converting lit to imp and keeping table of contents links etc | askyn | IMP | 11 | 10-04-2008 01:04 AM |