Comment 9 for bug 82674

Revision history for this message
Martin-Éric Racine (q-funk) wrote :

The script magic you propose for prerm should work well as-is.

For postinst, what I would use:

lpadmin -p PDF -E -v cups-pdf:/ -m PostscriptColor.ppd -o PageSize=$(paperconf) -o printer-is-shared=no

paperconf(1) from libpaper-utils (added to Depends) tells us the default paper size.

What I need before that is a way to check:

1) Is there already a printer called PDF? if there is, add a digit to the printer name we're about to create.

2) Is there any default printer already? If there is, don't set as default.