I am using MacBook Pro Mac OS 10.5 with related version of XCode. I am new to this development environment. I am developing C++ console/terminal applications (File->New project, then from the list on the left “Command line utility”, and on the right “C++ tool”.).
For C++ source code file, I want to print source file content with line number. Any ideas how to do this?
thanks in advance,
George
I found this article A Recipe to Pretty-Print Your iPhone Source in Xcode it uses enscript which is installed by Apple for Xcode on Snow Leopard so no need for macports etc.
You can get linenumbers by passing -C as an argument to the enscript executable called in the shell script