Re: [cups] print into pipe with cups 2.x

Jörg Thümmler <[email protected]> Mon, 21 Feb 2022 12:51:19 +0100
Newsgroups gmane.comp.printing.cups.general
Message-ID <[email protected]>
Am 21.02.22 um 11:36 schrieb Johannes Meixner:
> 
> Hello,
> 
> On 2022-02-21 10:16, Jörg Thümmler wrote:
>> Background: On the 1.x system the pipe URI did contain the
>> "cups_pipeprint" named pipe program and the name of the printer,
>> which was printing the job after handling in the pipe. I saw,
>> typical URIs as "cups_pipeprint&printer=printerxxx"
> 
> I don't know about "cups_pipeprint"
> but perhaps
> https://github.com/jsmeix/cups-backends
> might be a possible alternative for you?
> 
> It is all pure bash so you could at least adapt and enhance it
> as you specifically need it in your particular case.
> 
> 
> Kind Regards
> Johannes Meixner

Hi,

thank you very much,

i'm sorry if i didn't make clear the (maybe not so important) problem i 
have:

cups 2.x is accepting only a string without any space characters as 
deviceURI-string. Bash finds $1 usually separated by space character 
from command file name. So it's impossible to use a bash command with 
$1....$9 variables as a deviceURI string. It's not that hard to 
circumvent this (as i do with symlinks to the real used command and then 
splitting $0 into command and arguments), other methods maybe can use 
the jobs parameters, name etc.

I can't see at the moment how another backend will change the behavior 
of cups (at least of the web interface) not accepting space chars in the 
deviceURI string when adding a printer.

I tried the example

lpadmin -p queue_name -v 
'pipe:/path/to/command?option1=value1&-option2&value2' -E

but in no way the jobs sended over the queue will be done but remain 
active and the printer is stopped until i have a command named exactly 
as in the deviceURI string (which is impossible for the example)

but don't spend much time on this, my workaround works well and i hope i 
won't have that much printers that use this pipe mechanism.

-- 
cu

jth
_______________________________________________
cups mailing list
[email protected]
https://lists.cups.org/mailman/listinfo/cups