Xcode 4 how many lines of code
In this quick tip, you learn how to show line numbers in Xcode and how to quickly jump to a line of code. Fire up Xcode and create a project or a playground. A code editor without line numbers doesn't feel right. There is no menu item or keyboard shortcut to toggle line numbers in Xcode. Yes, this tool is just invented to make knowing how many lines I have easier. How to find out how many lines of code there are in an Xcode project?
Asked By: Dave. Answered By: Nathan Kinsinger. Answered By: Joshua Nozzi. Answered By: tiguero. Answered By: Esqarrouth. Answered By: Andrew McGregor. Answered By: Matthew Frederick. Answered By: Shan Shafiq. Answered By: RileyE. We are building a library of questions and answers, but the rapid recent development of Swift hurts answer relevance. Might be a topic for meta. Show 3 more comments.
Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown. The Overflow Blog. Does ES6 make JavaScript frameworks obsolete?
Podcast Do polyglots have an edge when it comes to mastering programming Featured on Meta. Now live: A fully responsive profile. Linked Related Hot Network Questions. Use above link to download '. Make sure that you enable execution permission on cloc PERL is already part of Mac OS and you can invoke the script this way to find out your number of lines you have written: perl cloc Stunner I like this better than my own answer.
You may need to download the script first. Then navigate to the directory where that script is and run that command with whatever file name you downloaded.
Should be cloc perl One last thing, I had to run span Moo as per error that appeared when running it for the 1st time so checkout for that one as well — Golan Shay.
Open up Terminal. Esqarrouth Esqarrouth In terminal, change into the project directory and run: find. Nice, but includes comments and blank lines and thus is not exactly what was asked for.
A LOC measure should be as independent of code formatting style as possible and thus a bunch of blank lines or comments between to logical parts in a file shouldn't count towards the sum. Maarten 1 1 silver badge 13 13 bronze badges. Matthew Frederick Matthew Frederick Note that Xcode Statisician doesn't deal with subdirs in your project at this point.
Quite a bit more manual work, unfortunately and recursive folder searching is easy to code , but it's workable. Seems it doesn't work at all with X-Code 4. Ah, bummer, it may be outdated now. Show 3 more comments. FelixSFD 5, 10 10 gold badges 41 41 silver badges bronze badges.
Shan Shafiq Shan Shafiq 9 9 silver badges 10 10 bronze badges. If you go to your project's directory in terminal and enter: find. RileyE RileyE For swift just removed everything and added.
WCByrne Alternatively, we can just add. Since most libraries and borrowed code are still in. Everyone has their own solution. And if they have their own prefix eg: "RE" , they could even do find. Nozzi's version doesn't work for me, but this one: find. Pascalius Pascalius
0コメント