HACKER Q&A
📣 W-Stool

What are you using to print source code these days?


I was an old school guy who always printed his reams of source code out on a 132 character dot matrix printer - green bar paper, everything. These days this is just not possible. What is the current thinking of printing source code if this is important to you?


  👤 dossy Accepted Answer ✓
> These days this is just not possible.

Why not?

I still format my code to an 80 column width.

I can still use `pr` to paginate my source for printing, and use `enscript` to produce a PostScript document of it, then `ps2pdf` to convert that to PDF, then I can spool that PDF to any printer.

And, on my home network, I have a HP LaserJet 2300dn and I can actually just shove the plain text output from `pr` straight to the JetDirect port on 9100/tcp.

What exactly is the obstacle that's preventing you from printing out your source code?


👤 pncnmnp
Maybe tangential, but what kind of source code did you all print out? Anything memorable? Also, what were the reasons for printing them out?

👤 ftxbro
sometimes you can print academic papers that have pseudocode in them it's like source code pseudocode is basically python anyway

👤 GianFabien
I rarely print out source code. Only when I want to carefully study some tricky code written by others. I use LibreOffice Writer, landscape with suitable sized font. Sometimes I leave space to the side for my scribbling, notes, lines, etc. Print on a laser printer.

👤 simonblack
Very rarely these days do I print source-code.

But on the odd occasions that I do, I print the code with a monospaced font directly to .PDF.

I then transfer that .PDF to a large-format Kindle (like the Scribe).

When I don't need that anymore I delete it from the Kindle, but retain a copy of the .PDF for future use if necessary.