1.0.2 • Published 3 years ago

node-lp v1.0.2

Weekly downloads
81
License
-
Repository
github
Last release
3 years ago

node-lp

node-lp is an adapter to the unix 'lp(1)' command allowing files to be submitted for printing or altering a pending job. This will only work on Linux at the moment however if anyone wants a windows port then that might happen.

Requirements

You need cups installed to use this module.

Installation

node-lp can then be installed via NPM

npm install node-lp

Then, require the module

var lp = require("node-lp");
var options = {};

printer = lp(options);

printer.queue ("/tmp/test-file.pdf");

Usage

lp.queue(fileLocation, callback)

lp.queue(buffer, callback)

lp.stop(jobid)

lp.resume(jobid)

lp.hold(jobid)

Options Available

OptionDescription
destinationPrints files to the named printer.
hostnameChooses an alternate server.
portChooses an alternate server port (only use if hostname is specified).
usernameSpecifies the username to use when connecting to the server.
encryptionForces encryption when connecting to the server.
digitalCopyAllows logging of what excatly is being printed.
argsPass custom arguments to lp (in array).

Licence

Licensed under the New BSD License

1.0.2

3 years ago

1.0.1

6 years ago

1.0.0

6 years ago