MobileRead Forums

MobileRead Forums (https://www.mobileread.com/forums/index.php)
-   Plugins (https://www.mobileread.com/forums/forumdisplay.php?f=268)
-   -   Convert Books (https://www.mobileread.com/forums/showthread.php?t=255132)

crutledge 01-28-2015 08:07 AM

Convert Books
 
Has any thought been given to making the Calibre "Convert Books" available in Sigil?

Doitsu 01-28-2015 10:35 AM

Quote:

Originally Posted by crutledge (Post 3034796)
Has any thought been given to making the Calibre "Convert Books" available in Sigil?

You could use my Kindlegen plugin to generate azw3 or hybrid mobi files or DiapDealer's KindleImport plugin to convert Kindle books to ePubs.

For your daily releases you could also use a batch file to generate .azw3 and .lrf files.

Code:

DEL conversion.log
FOR %%f IN ("*.epub") DO  (
    "C:\Program Files\Calibre2\ebook-convert.exe" "%%f" "%%~nf.azw3" >> conversion.log
    "C:\Program Files\Calibre2\ebook-convert.exe" "%%f" "%%~nf.lrf" >> conversion.log
)

Simply create a text file with a .bat extension, paste the above code into it and save it.
Then copy the .bat file to the folder that contains the epub file(s) and double-click the batch file.
(Obviously, this will only work if C:\Program Files\Calibre2\ebook-convert.exe exists; if you've installed Calibre in a different location, you'll need to adjust the file path.)

eschwartz 01-28-2015 11:40 AM

Or simply use ebook-convert.exe, since calibre installs itself to the system %PATH%

DiapDealer 01-28-2015 11:59 AM

Quote:

Originally Posted by eschwartz (Post 3034876)
Or simply use ebook-convert.exe, since calibre installs itself to the system %PATH%

The ability to customize/specify the location of ebook-convert would still be recommended. If only to thwart that person who's waiting to pounce with "I have the portable version of calibre installed and this plugin doesn't work!" ;)
(or does it modify the ℅PATH% too?)

eschwartz 01-28-2015 12:05 PM

Well, obviously the portable version does not meet the criteria of being installed, thus people can be expected to ask/think critically about the matter.

Whereas any install will be added to the %PATH% regardless of install folder, so skipping the path can only be a net gain over specifying the default.

School system here, so calibre is "installed" via a scripted msiexec hack into %USERPROFILE%\PFiles\ and added to user %PATH%. That works too...

DiapDealer 01-28-2015 12:54 PM

While we're critically thinkng, what would most people call that program that I download and run in order to put the portable version of calibre on my PC?

eschwartz 01-28-2015 02:52 PM

If they are fooled by the word "installer" and not clued in by the word "portable" (and the fact that the portable instance is being used on another computer), they may be the type who cannot figure out how to edit the batch script even with a Youtube video for directions.

Considering that you have to deliberately use the portable version instead, and have an awkward workflow to use it, you would have sufficient warning that that is not the normal way of things.

BetterRed 01-28-2015 04:46 PM

Quote:

Originally Posted by DiapDealer (Post 3034887)
(or does it modify the ℅PATH% too?)

No, I have 3 instances of portable installed (2x2.17 and 1x1.48)- %PATH% has no knowledge of them - thank goodness. I removed the path to the 32bit.

BR

eschwartz 01-28-2015 06:40 PM

The path is modified by the installer.msi -- not by calibre.

BetterRed 01-28-2015 08:08 PM

2 Attachment(s)
Quote:

Originally Posted by eschwartz (Post 3035101)
The path is modified by the installer.msi -- not by calibre.

But only if the person who built the msi requested the path be modified, and then only if person installing the msi accepts that it be done.

Attachment 134286

Fast Picture Viewer does a bunch of other things that calibre doesn't do, because they would be meaningless. FPV does not put itself in the path because it would be meaningless, as there are no FPV command line programs.

Attachment 134287

BR

eschwartz 01-28-2015 11:56 PM

...

I assumed that much was a given.

Yes, I am aware that the calibre MSI has been specifically designed to include an option to modify the %PATH%. ;)

BetterRed 01-29-2015 02:32 AM

Quote:

Originally Posted by eschwartz (Post 3035227)
...

I assumed that much was a given.

To plagiarise and paraphrase Plato and Aquinas - "A wise man always states his assumptions lest others be led blindly into making the wrong conclusions." ;)

BR


All times are GMT -4. The time now is 08:31 PM.

Powered by: vBulletin
Copyright ©2000 - 3.8.5, Jelsoft Enterprises Ltd.
MobileRead.com is a privately owned, operated and funded community.