Revision 24774,
605 bytes
checked in by broder, 14 years ago
(diff) |
printing-config: Exclude statements that can't be unit-tested from coverage calculations.
|
-
Property svn:executable set to
*
|
Rev | Line | |
---|
[24763] | 1 | #!/usr/bin/python |
---|
| 2 | """Debathena lp wrapper script. |
---|
| 3 | |
---|
| 4 | A script that intelligently determines whether a command was intended |
---|
| 5 | for CUPS or LPRng and sends it off in the right direction |
---|
| 6 | """ |
---|
| 7 | |
---|
| 8 | |
---|
| 9 | import sys |
---|
| 10 | |
---|
| 11 | from debathena.printing import common |
---|
| 12 | from debathena.printing import simple |
---|
| 13 | |
---|
| 14 | |
---|
| 15 | opts = ( |
---|
| 16 | (common.SYSTEM_CUPS, 'EU:cd:h:mn:o:q:st:H:P:i:'), |
---|
| 17 | (common.SYSTEM_LPRNG, 'ckmprswBGYd:D:f:n:q:t:'), |
---|
| 18 | ) |
---|
| 19 | |
---|
| 20 | |
---|
| 21 | queue_opt = '-d' |
---|
| 22 | |
---|
| 23 | |
---|
| 24 | def _main(args): |
---|
| 25 | return simple.simple('lp', opts, queue_opt, args) |
---|
| 26 | |
---|
| 27 | |
---|
| 28 | def main(): |
---|
[24774] | 29 | sys.exit(_main(sys.argv)) # pragma: nocover |
---|
[24763] | 30 | |
---|
| 31 | |
---|
| 32 | if __name__ == '__main__': |
---|
[24774] | 33 | main() # pragma: nocover |
---|
Note: See
TracBrowser
for help on using the repository browser.