Re: Code beautification and/or printing utilities that are not part of an editor
On Fri, 2007-04-20 at 10:23 +0100, Tom Evans wrote: > On Thu, 2007-04-19 at 15:10 -0600, Andrew Falanga wrote: > > Another question for everyone. Are there any programs, hopefully > > available in the ports, that one can use to print source code files to > > a printer (or create as a postscript file)? > > > > I'd like something that I can feed a C++ program, have it parse > > through the code, print line numbers to the left of the page and > > (optionally) color code the syntax. Does anything like this exist? > > > > If it's something as simple as a string of chained command line aps, > > hey, that's fine. Please someone point me in the correct direction. > > > > Andy > > ___ > > freebsd-questions@freebsd.org mailing list > > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > > To unsubscribe, send any mail to "[EMAIL PROTECTED]" > > Assuming you can print with lpr(1): > > vim "+syntax enable" "+number" "+hardcopy" file.cc > > I'd put "syntax enable" in your ~/.vimrc , and the other attrs can be > shortened to: > > vim "+nu" "+ha" file.cc My bad, I hadn't actually tried that! The correct version should be: vim "+syntax enable" "+set printoptions=number:y" "+hardcopy" file.cc vim "+syntax enable" "+set popt=number:y" "+ha" file.cc signature.asc Description: This is a digitally signed message part
Re: Code beautification and/or printing utilities that are not part of an editor
On Thu, 2007-04-19 at 15:10 -0600, Andrew Falanga wrote: > Another question for everyone. Are there any programs, hopefully > available in the ports, that one can use to print source code files to > a printer (or create as a postscript file)? > > I'd like something that I can feed a C++ program, have it parse > through the code, print line numbers to the left of the page and > (optionally) color code the syntax. Does anything like this exist? > > If it's something as simple as a string of chained command line aps, > hey, that's fine. Please someone point me in the correct direction. > > Andy > ___ > freebsd-questions@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to "[EMAIL PROTECTED]" Assuming you can print with lpr(1): vim "+syntax enable" "+number" "+hardcopy" file.cc I'd put "syntax enable" in your ~/.vimrc , and the other attrs can be shortened to: vim "+nu" "+ha" file.cc signature.asc Description: This is a digitally signed message part
Re: Code beautification and/or printing utilities that are not part of an editor
On Apr 19, 2007, at 4:10 PM, Andrew Falanga wrote: Another question for everyone. Are there any programs, hopefully available in the ports, that one can use to print source code files to a printer (or create as a postscript file)? I'd like something that I can feed a C++ program, have it parse through the code, print line numbers to the left of the page and (optionally) color code the syntax. Does anything like this exist? a2ps was once a nice and simple ascii to PS converter then it bloated into a source code pretty-printer. Has been at least 10 years since I used it. GNU indent is a very useful code reformatter. -- David Kelly N4HHE, [EMAIL PROTECTED] Whom computers would destroy, they must first drive mad. ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: Code beautification and/or printing utilities that are not part of an editor
On 4/19/07, Andrew Falanga <[EMAIL PROTECTED]> wrote: Another question for everyone. Are there any programs, hopefully available in the ports, that one can use to print source code files to a printer (or create as a postscript file)? I'd like something that I can feed a C++ program, have it parse through the code, print line numbers to the left of the page and (optionally) color code the syntax. Does anything like this exist? If it's something as simple as a string of chained command line aps, hey, that's fine. Please someone point me in the correct direction. Andy ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]" You might be able to find what you are looking for here: http://www.freebsd.org/cgi/ports.cgi?query=printing&stype=all&sektion=all I see a few potentially interesting ports, although I have no personal experience with them. http://cvsweb.freebsd.org/ports/print/mp-a4 http://cvsweb.freebsd.org/ports/print/mp-letter Good Luck, Gable ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: Code beautification and/or printing utilities that are not part of an editor
Another question for everyone. Are there any programs, hopefully available in the ports, that one can use to print source code files to a printer (or create as a postscript file)? I'd like something that I can feed a C++ program, have it parse through the code, print line numbers to the left of the page and (optionally) color code the syntax. Does anything like this exist? If it's something as simple as a string of chained command line aps, hey, that's fine. Please someone point me in the correct direction. I seem to remember using enscript to do this at one point... not sure about the color coding, but the rest it will do I think... even cruch 2/4 pages onto one sheet which is nice sometimes. http://www.codento.com/people/mtr/genscript/ -philip ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: Code beautification and/or printing utilities that are not part of an editor
On Thu, Apr 19, 2007 at 03:10:47PM -0600, Andrew Falanga wrote: > Another question for everyone. Are there any programs, hopefully > available in the ports, that one can use to print source code files to > a printer (or create as a postscript file)? > > I'd like something that I can feed a C++ program, have it parse > through the code, print line numbers to the left of the page and > (optionally) color code the syntax. Does anything like this exist? http://www.codento.com/people/mtr/genscript/ -- Thomas E. Dickey http://invisible-island.net ftp://invisible-island.net pgpLIsp8XGWV5.pgp Description: PGP signature