I wanted to print a checklist as the final task in a release management Ant job.
We have a predominantly windows environment on the desktop, so I thought I'd try using the DOS print command, but was initially foiled when trying to use a network printer.
I was then mislead slightly by this: NET USE LPT1: \\MY_SERVER\PRINTER which I found here.
In the end the obvious solution (to use the share name for the device) was the right one.
Reproduced below, it works a dream, now you too can spam your office printers!