Reputation: 287
I installed docker and run pdf2htmlEX through it
alias pdf2htmlEX="docker run -ti --rm -v ~/pdf:/pdf bwits/pdf2htmlex pdf2htmlEX"
pdf2htmlEX -h
pdf2htmlEX --zoom 1.3 test.pdf
This is my path and the pdf's contained inside:
~/Desktop/pdf$ ls
test.pdf testpdf.pdf
When running the following commands:
df2htmlEX --zoom 1.3 test.pdf
df2htmlEX test.pdf
df2htmlEX pdf/test.pdf
df2htmlEX ~pdf/test.pdf
and other combinations with the full path before test.pdf I continue to get unable to read the file errors.
I/O Error: Couldn't open file 'test.pdf': No such file or directory.
Error: Cannot read the file
I am not sure if permissions is a cause, but when checking on user permissions it has read and write:
-rw-r--r--@ 1 test.pdf
-rw-r--r--@ 1 testpdf.pdf
Any idea on why it is not finding or cannot read the pdf file that is there? I am trying to convert it to .html
Upvotes: 1
Views: 2745
Reputation: 21
Host path should be directed like this.
docker run -ti --rm -v /Users/<path>:/pdf bwits/pdf2htmlex pdf2htmlEX test.pdf
Please refer to https://docs.docker.com/engine/tutorials/dockervolumes/
Upvotes: 2
Reputation: 287
not sure if other people ran into this problem, but the documentation was unclear to me.
brew install pdf2htmlex
and then restart your terminal did the trick for me. I am not sure if that was required with docker spinning up pdf2htmlex or not, but it worked for me.
Upvotes: 1