CLI-tool which opens a pdf file specified by command line argument in the form of URL or local filepath with pdf.js.
- docker environment (You have to be able to execute docker commands without
sudo
) - Python 3 (>=3.6)
- browser-launcing command depending on your platform
wslview
on WSL- Environment variable
$BROWSER
(e.g.$BROWSER=chromium
) on Linux
$ git clone [email protected]:monado3/pdfjs-broker.git
$ cd pdfjs-broker
$ docker build -t pdfjs_url ./pdfjs_server_url
$ docker build -t pdfjs_file ./pdfjs_server_file
- Configure browser launcing
- Add $BROWSER={your browser you want to use for reading pdf files} to environment variable (on Linux)
- install
wslu
forwslview
command (on WSL)
$ ln -s {/foo/bar/broker.py} /usr/local/bin/pdfjs
$ pdfjs [-u <URL of a pdf file> | -f <pdf file path>]