It would be useful if pdftotext had a mode to accept text from stdin, as it already can pipe its results to stdout. This is useful in gateways and frontends that don't want to (or can't) use an temporary on-disk file. I'll attach a very small patch that does this.
Created attachment 6051 [details] [review] patch to implement the requested feature Example usage: pdftotext - - < foo.pdf > foo.txt
fixed in cvs
This seems to have regressed. In poppler 0.8.2, the invocation pdftotext - - complains that "Error: Document base stream is not seekable".
Not sure why this is marked as cairo backend. Probably belongs in general.
That's right, the base stream needs to be seekable or otherwise poppler does not work at all. On the other hand i just tried to do ./utils/pdftotext - < ~/okularfiles/pdf/alumnes_normativa.pdf and it created a -.txt file containing the text contents of alumnes_normativa.pdf I'm not sure what could cause that behaviour change. Which shell are you using? I tried with GNU bash, version 3.2.33(1)-release (x86_64-pc-linux-gnu) and zsh 4.3.4 (x86_64-unknown-linux-gnu) and both worked
Should be working in the latests 0.13.x releases
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.