-
-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathhp-printer-app.1
More file actions
352 lines (335 loc) · 9.58 KB
/
hp-printer-app.1
File metadata and controls
352 lines (335 loc) · 9.58 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
.\"
.\" HP Printer Application man page
.\"
.\" Copyright © 2020-2024 by Michael R Sweet
.\"
.\" Licensed under Apache License v2.0. See the file "LICENSE" for more
.\" information.
.\"
.TH hp-printer-app 1 "hp-printer-app" "2024-02-03" "Michael R Sweet"
.SH NAME
hp-printer-app \- hp printer application
.SH SYNOPSIS
.B hp-printer-app
[
.I SUB-COMMAND
] [ OPTIONS ] [ FILES ]
.SH DESCRIPTION
.B hp-printer-app
is a printer application that can be run standalone or as a dedicated IPP Everywhere network service.
.B hp-printer-app
supports printing JPEG images, PNG images, Apple/PWG raster files, and printer-specific files to USB and network PCL printers.
If no sub-command is specified, "submit" is assumed.
.SH SUB-COMMANDS
The following sub-commands are recognized by
.B hp-printer-app:
.TP 5
.B add
Add a printer queue.
.TP 5
.B cancel
Cancel one or more print jobs.
.TP 5
.B default
Get/Set the default printer queue.
.TP 5
.B delete
Delete a printer queue.
.TP 5
.B devices
List connected printers.
.TP 5
.B drivers
List the supported drivers.
.TP 5
.B jobs
List pending print jobs.
.TP 5
.B modify
Modify a printer queue.
.TP 5
.B options
List supported options.
.TP 5
.B printers
List the printer queues.
.TP 5
.B server
Start a server.
.TP 5
.B shutdown
Shutdown a running server.
.TP 5
.B status
Show the status of a printer or all printers.
.TP 5
.B submit
Submit a file for printing.
.SH OPTIONS
The following options are recognized by
.B hp-printer-app:
.TP 5
.B \-a
Cancels all jobs ("cancel" sub-command).
.TP 5
\fB\-d \fIPRINTER\fR
Specifies the printer.
.TP 5
\fB\-h \fIHOST\fR
Specifies the server hostname.
.TP 5
\fB\-j \fIJOB-ID\fR
Specifies the job ID ("cancel" sub-command).
.TP 5
\fB\-m \fIDRIVER-NAME\fR
Specifies the driver name ("add" sub-command).
.B hp-printer-app
supports the "pcl_deskjet" (HP DeskJet, OfficeJet, and Photosmart printers), "pcl_laserjet" (HP LaserJet printers), and "pcl_generic" (PCL-compatible laser printers from other vendors) driver names.
.TP 5
\fB\-n \fICOPIES\fR
Specifies the number of copies.
.TP 5
\fB\-o media=\fISIZE-NAME\fR
Specifies the paper size.
.B hp-printer-app
supports custom PWG "self-describing" media size names of the form "custom_name_WIDTHxLENGTHin" (size in inches) and "custom_name_WIDTHxLENGTHmm" (size in millimeters) as well as the following standard sizes: "na_ledger_11x17in", "na_legal_8.5x14in", "na_letter_8.5x11in", "na_executive_7x10in", "iso_a3_297x420mm" "iso_a4_210x297mm", "iso_a5_148x210mm", "jis_b5_182x257mm", "iso_b5_176x250mm", "na_number-10_4.125x9.5in", "iso_c5_162x229mm", "iso_dl_110x220mm", "na_monarch_3.875x7.5in".
.TP 5
\fB\-o media-source=\fITRAY-NAME\fR
Specifies the paper tray.
.B hp-printer-app
supports the following trays: "default" (default/auto tray), "manual" (manual feed), "envelope", "tray-1", "tray-2", "tray-3", or "tray-4", depending on the printer.
.TP 5
\fB\-o media-type=\fITYPE-NAME\fR
Specifies the paper type.
.B hp-printer-app
supports the following types: "stationery" (plain paper), "stationery-inkjet" (inkjet paper), "stationery-letterhead" (letterhead paper), "envelope", "transparency", and "photographic" (photo paper of different kinds), depending on the printer.
.TP 5
.B \-o orientation-requested=portrait
Print images in portrait orientation.
.TP 5
.B \-o orientation-requested=landscape
Print images in landscape (90 degrees counter-clockwise) orientation.
.TP 5
.B \-o orientation-requested=reverse-portrait
Print images in reverse-portrait (upside down) orientation.
.TP 5
.B \-o orientation-requested=reverse-landscape
Print images in reverse-landscape (90 degrees clockwise) orientation.
.TP 5
.B \-o orientation-requested=none
Print images in automatic (portrait or landscape) orientation.
.TP 5
.B \-o print-color-mode=auto
Print in color or grayscale as needed.
.TP 5
.B \-o print-color-mode=monochrome
Print in grayscale.
.TP 5
.B \-o print-color-mode=color
Print in color (HP DeskJet/Photosmart printers only).
.TP 5
.B \-o print-content-optimize=auto
Optimize printing automatically based on the type and content of the file.
.TP 5
.B \-o print-content-optimize=graphic
Optimize printing for graphics only.
.TP 5
.B \-o print-content-optimize=photo
Optimize printing for photos.
.TP 5
.B \-o print-content-optimize=text
Optimize printing for text only.
.TP 5
.B \-o print-content-optimize=text-and-graphic
Optimize printing for text and graphics.
.TP 5
\fB\-o print-quality=draft\fR
Print using draft quality.
.TP 5
\fB\-o print-quality=normal\fR
Print using normal quality.
.TP 5
\fB\-o print-quality=high\fR
Print using high/best quality.
.TP 5
\fB\-o printer-geo-location=geo:\fI=LATLON\fR
Specifies the geographic location of the printer as a "geo:" URI ("add" and "modify" sub-commands).
.TP 5
\fB\-o printer-location\fI=LOCATION\fR
Specifies the human-readable location, for example "Rack 42" ("add" and "modify" sub-commands).
.TP 5
\fB\-o printer-organization\fI=ORGANIZATION\fR
Specifies the organization name, for example "Acme, Inc." ("add" and "modify" sub-commands).
.TP 5
\fB\-o printer-organizational-unit\fI=UNIT\fR
Specifies the organizational unit, for example "Accounting Department" ("add" and "modify" sub-commands).
.TP 5
\fB\-o printer-resolution=300dpi\fR
.TP 5
\fB\-o printer-resolution=600dpi\fR
Specifies the print resolution in dots per inch.
.TP 5
\fB\-o sides=one-sided\fR
Print on one side only.
.TP 5
\fB\-o sides=two-sided-long-edge\fR
Print on both sides for portrait output.
.TP 5
\fB\-o sides=two-sided-short-edge\fR
Print on both sides for landscape output.
.TP 5
\fB\-t \fITITLE\fR
Specifies the job title ("submit" sub-command).
.TP 5
\fB\-u \fIURI\fR
Specifies an "ipp:" or "ipps:" printer/server.
.TP 5
\fB\-v \fIDEVICE-URI\fR
Specifies a "socket:" or "usb:" device ("add" sub-command).
.SH SERVER OPTIONS
The following options are recognized by the "server" sub-command:
.TP 5
\fB\-o admin\-group=\fIGROUP-NAME\fR
Specifies the administrative group name when using PAM for authentication.
.TP 5
\fB\-o auth\-server=\fIPAM-SERVICE\fR
Specifies the PAM service to use for authentication.
.TP 5
\fB\-o listen\-hostname=\fIHOSTNAME\fR
.TP 5
\fB\-o listen\-hostname=*\fR
Specifies the listen hostname for incoming connections.
The "*" name specifies the wildcard listener for any network interface and is the default.
.TP 5
\fB\-o log\-file=\fIFILENAME\fR
.TP 5
\fB\-o log\-file=-\fR
.TP 5
\fB\-o log\-file=syslog\fR
Specifies the log file.
The name "-" sends log messages to the standard error, while "syslog" sends log messages to the local logging service.
.TP 5
\fB\-o log\-level=fatal\fR
.TP 5
\fB\-o log\-level=error\fR
.TP 5
\fB\-o log\-level=warn\fR
.TP 5
\fB\-o log\-level=info\fR
.TP 5
\fB\-o log\-level=debug\fR
Specifies the level of verbosity in the log file.
The value "fatal" specifies log messages that cause the server to abort, while the value "debug" specifies the highest level of verbosity.
.TP 5
\fB\-o server\-hostname=\fIHOSTNAME\fR
Specifies the network hostname that is advertised for the server.
The default is the value reported by the
.BR hostname (1)
command.
.TP 5
\fB\-o server\-name=\fIDNS-SD-NAME\fR
Specifies the DNS-SD service name that is advertised for the server.
The default is "hp-printer-app".
.TP 5
\fB\-o server\-options=\fIOPTION[,OPTION,...]\fR
Specifies a comma-delimited list of server options.
By default,
.B hp-printer-app
uses the "multi-queue" and "web-interface" options.
The following options are supported:
.TP 10
.B dnssd\-host
When resolving conflicts, add the DNS-SD hostname instead of a serial number or UUID.
.TP 10
.B no\-multi\-queue
Do no support multiple print queues.
.TP 10
.B raw\-socket
Provide a raw ("JetDirect") socket for each printer on port 91xx.
.TP 10
.B usb\-printer
Enable a USB printer gadget for the default printer (Linux only for Raspberry Pi and similar embedded SBCs).
.TP 10
.B no\-web\-interface
Disables the web interface.
.TP 10
.B web\-log
Enables the log file web page.
.TP 10
.B web\-network
Enables the network settings web page.
.TP 10
.B web\-remote
Enables remote queue management.
.TP 10
.B web\-security
Enables the user/password settings web page.
.TP 10
.B web\-tls
Enables the TLS settings web page.
.TP 10
.B no\-tls
Disables TLS support.
.TP 5
\fB\-o server\-port=\fIPORT\fR
Specifies the port number that is used.
The default is in the range of 8000 to 8999.
.TP 5
\fB\-o spool\-directory=\fIDIRECTORY\fR
Specifies the spool directory for print jobs.
.SH EXAMPLES
Add a PCL laser printer "laser" at IP address 11.22.33.44:
.nf
hp-printer-app add -v socket://11.22.33.44 -m pcl_laserjet -d laser
.fi
Print a PCL file to the printer:
.nf
hp-printer-app -d laser filename.pcl
.fi
Print a photo to US Letter media:
.nf
hp-printer-app -d laser -o media=na_letter_8.5x11in -o print-quality=high photo.jpg
.fi
List supported options:
.nf
hp-printer-app options
.fi
List queued jobs:
.nf
hp-printer-app jobs
.fi
List configured printers:
.nf
hp-printer-app printers
.fi
Show status of server:
.nf
hp-printer-app status
.fi
List network and USB printers that can be added:
.nf
hp-printer-app devices
.fi
.SH CONFIGURATION FILES
.B hp-printer-app
will look for configuration files in the following locations:
.IP \(bu 1
$HOME/.config/hp-printer-app.conf
.IP \(bu 1
$HOME/Library/Application Support/hp-printer-app.conf
.IP \(bu 1
$SNAP_COMMON/hp-printer-app.conf
.IP \(bu 1
%USERPROFILE%/AppData/Local/hp-printer-app.conf
.IP \(bu 1
/Library/Application Support/hp-printer-app.conf
.IP \(bu 1
/etc/hp-printer-app.conf
.IP \(bu 1
/usr/local/etc/hp-printer-app.conf
.PP
Each file consists of comment lines starting with the '#' character and option lines of the form "NAME=VALUE ... NAME=VALUE".
.SH SEE ALSO
https://www.msweet.org/hp-printer-app
.SH COPYRIGHT
Copyright \[co] 2019-2024 by Michael R Sweet.