gitbook-cli
gitbook-cli copied to clipboard
Cannot convert to pdf or epub on Windows
I'm using: Node v4.3 (LTS) Win7 and I get this error:
gitbook pdf ./FOLDER ./PDFFOLDER
Error: Command failed: C:\Windows\system32\cmd.exe /s /c "ebook-convert C:\cygwin64\tmp\tmp-142762n41q40\SUMMARY.html C:\cygwin64\tmp\tmp-142762n41q40\index.pdf
..... (Config stuff I don't want to be shown) ...
'ebook-convert' is not recognized as an internal or external command,
operable program or batch file.
I've tried install ebook-convert as a global node package and I have, but it always installs in as a sub directory of the npm binaries PREFIX/node_modules/ebook-convert/
Any idea what is wrong?
Looks like issue gitbookIO/gitbook#1516
@jakeecolution download this https://calibre-ebook.com/download_windows64 and it will work like charm.
Sincerely, Gerasimos Maropoulos, author of iris
@kataras Thank you for your solution, it indeed works. However, in my case installing Calibre
alone didn't solve the problem of Windows
not recognizing the ebook-convert
command, in addition to that I had to add the Calibre
installation path
to the PATH
environment variable. So in Windows under Environment Variables
-> Path
-> Edit
-> New
and then I had to put the installation Path
of Calibre
which is in my case and by default C:\Program Files\Calibre2
so that Windows has direct access to the ebook-convert.exe
. Then I had to restart not only my command line terminal
but also my IDE
first.