node-poppler
node-poppler copied to clipboard
Why is the binPath needed?
Prerequisites
-
[X] I have written a descriptive title
-
[X] I have searched existing feature requests to ensure it has not already been proposed
-
[X] I agree to follow the Code of Conduct that this project adheres to
Description
First, thank you for making this!
It took me a while to figure out what I was looking for in terms of the poppler-utils directory, but I figured it out. It does seem like brew install poppler put the utils onto the path, though, so I just wondering why this path is needed. On my local machine this path will be different from in CI, so just curious if there is a trick to get around providing the path or something.
Thanks @testlabauto, this repo was first built for use in a Windows environment, where finding a poppler binary isn't/wasn't as simply as running brew install poppler
, so the binPath
arg was there as it was assumed the binary would be dumped somewhere.
It hadn't crossed my mind that it could be added to the path env variable though, this is something I can look at making the constructor check.
Great. Thanks, @Fdawgs !
I'm hopping onto this issue as it concerns in a way a topic i was working on recently. Yes it's very easy on a self controlled mac to add poppler using homebrew but in a scenario where this package is part of an e.g. electron app where it's not possible to install homebrew it would be very nice if poppler could be provided like it's done for windows. On windows it's working super smooth without thinking about it's core dependencies.
I've tried it actually but my abilities to compile poppler are too limited and so i didn't made it into a solution i can contribute as a pull request.
So my question is if this would be technically possible.
Thanks for the great work!
Better late than never, as part of 7.2.0, the binPath is no longer required!
The constructor will attempt to find the pdfinfo
Poppler binary in the PATH environment variable and use that as the path for all of the Poppler binaries, this was written under the assumption poppler-utils was installed and so all the binaries will be in the same place i.e. /usr/bin
.