Welcome to the Linux Foundation Forum!

Printing code in color to color printer?

Hey,

Someone once showed me a simple command line way to print a file of code (Perl, Bash, etc.) on a color printer that honored the syntax highlighting. I have since forgotten it - anyone know what this might have been?

thx

Comments

  • Posts: 647
    atreyu wrote:
    Hey,

    Someone once showed me a simple command line way to print a file of code (Perl, Bash, etc.) on a color printer that honored the syntax highlighting. I have since forgotten it - anyone know what this might have been?

    thx

    If you pipe the coloured text to the printer it should work...

    Or did you mean something like "fileutil"?

    Regards
  • Posts: 216
    i just gave up and used gedit - never used fileutil tho. if i get time...

    EDIT: or, it can be done right in vim, i've just learned. cool. this is one of several ways to do it w/vim that worked for me:
    1. vim -me -e -c ":hardcopy >%.ps" -c ":q" test.sh
    2. lp -d COLOR_PRINTER_NAME test.sh.ps
    more at http://aplawrence.com/Girish/vim-tips.html for anyone interested...

Welcome!

It looks like you're new here. Sign in or register to get started.
Sign In

Welcome!

It looks like you're new here. Sign in or register to get started.
Sign In

Categories

Upcoming Training