<?xml version="1.0"?>
<rss version="2.0">
	<channel>
		<title>Total number of lines in project</title>
		<link>http://www.allegro.cc/forums/view/554601</link>
		<description>Allegro.cc Forum Thread</description>
		<webMaster>matthew@allegro.cc (Matthew Leverton)</webMaster>
		<lastBuildDate>Thu, 22 Dec 2005 23:47:55 +0000</lastBuildDate>
	</channel>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>I asked this in DevC++ mailing list(don&#39;t know why!) but can&#39;t get responses yet probably for that digest thing. Here it is:</p><p>&gt; I like to see how many lines of code I wrote, but<br />&gt; the project properties shows them per file. Is<br />&gt; there a way to count the total number of lines in<br />&gt; the whole project?</p><p>Currently I count them in &quot;Project Properties&quot; and write all numbers to windows calculator. With file numbers increasing that became harder.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Murat AYIK)</author>
		<pubDate>Wed, 21 Dec 2005 22:47:14 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>You could write a little C/C++ program that simply reads the lines of every cpp file in the current directory and calculates the total for you.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Onewing)</author>
		<pubDate>Wed, 21 Dec 2005 23:21:27 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><ol><li><p>Download <a href="http://unxutils.sourceforge.net/">Unix tools for Windows</a>:</p></li><li><p>Or if you are too lazy to do that, then:</p></li></ol><p>
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Matthew Leverton)</author>
		<pubDate>Wed, 21 Dec 2005 23:29:16 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Or use wc?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Marcello)</author>
		<pubDate>Wed, 21 Dec 2005 23:34:27 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>No need to use cat. wc * will print the total counts for all files at the bottom.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Evert)</author>
		<pubDate>Thu, 22 Dec 2005 00:19:16 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
You could write a little C/C++ program that simply reads the lines of every cpp file in the current directory and calculates the total for you.
</p></div></div><p>
This might be useful and easy. I need that info only for my main project, so a totally hardcoded prog can do what I want.</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
Or if you are too lazy to do that, then:<br />type *.c &gt; bigfile.c<br />Open up bigfile.c and count the lines.
</p></div></div><p>
Very nice! Combining this with the previous idea can decrease the coding time of that utility from 5 mins to 2 mins:)</p><p>EDIT:<br />I found the cat and wc tools but failed to use them. They start a console where I can write some commands apparently but I don&#39;t know what to write there.</p><p>EDIT2:<br />Nah, nevermind! I liked the &quot;do-it-yourself&quot; idea. It may turn into something better one day.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Murat AYIK)</author>
		<pubDate>Thu, 22 Dec 2005 00:29:06 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
What is that?(I really don&#39;t know!)
</p></div></div><p>
It gives you the number of lines, words, and characters. Just read my post, point 1. Follow the link to download. </p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
I found the cat and wc tools but failed to use them. They start a console where I can write some commands apparently but I don&#39;t know what to write there.
</p></div></div><p>
Copy them to your Windows folder. Go to your programming folder (within a shell) and type:</p><p><tt>wc *.c</tt>
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Matthew Leverton)</author>
		<pubDate>Thu, 22 Dec 2005 00:37:51 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Or add the folder they&#39;re in to your system path (might be a better idea).</p><p>Marcello
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Marcello)</author>
		<pubDate>Thu, 22 Dec 2005 02:18:57 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Use grep to remove blank lines and comments, then wc to count. Maybe... <i>cat *.c | grep -v &quot;^\s*/*.*&quot; | grep -v &quot;^\s*//&quot; | grep -v &quot;^\s*$&quot; | wc -l</i> will work.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (ReyBrujo)</author>
		<pubDate>Thu, 22 Dec 2005 02:27:23 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>That&#39;s cheating! You&#39;re supposed to include comments and blank lines. <img src="http://www.allegro.cc/forums/smileys/wink.gif" alt=";)" /></p><p>Marcello
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Marcello)</author>
		<pubDate>Thu, 22 Dec 2005 03:01:36 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Try <a href="http://www.dwheeler.com/sloccount/">sloccount</a>.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Thomas Fjellstrom)</author>
		<pubDate>Thu, 22 Dec 2005 03:12:49 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
Use grep to remove blank lines and comments, then wc to count. Maybe... cat *.c | grep -v &quot;^\s*/*.*&quot; | grep -v &quot;^\s*//&quot; | grep -v &quot;^\s*$&quot; | wc -l will work.
</p></div></div><p>
What is that, ASCII art?:) I think it would be better to post a feature-request to the bloodshed guys.</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
That&#39;s cheating! You&#39;re supposed to include comments and blank lines.
</p></div></div><p>
That&#39;s why I like DevCpp&#39;s built-in counter. It reports them seperately. I keep three numbers in my &quot;comment.h&quot; file; total lines, without empty lines and code lines only. The third doesn&#39;t really help your self-confidence;)</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
Try sloccount
</p></div></div><p>
Seems like not so Windows-friendly!</p><p>I will try something tomorrow, it&#39;s 11PM. And sorry I&#39;m out of cookies, Matthew gave me only one plate to serve:)(I know, wrong forum category!)
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Murat AYIK)</author>
		<pubDate>Thu, 22 Dec 2005 03:26:00 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Some quite useless statistics about allegro. Statistics generated by sloccount.</p><p>Latest SVN version of 4.2:</p><p>Totals grouped by language (dominant language first):<br />ansic:       126573 (83.88%)<br />asm:          17018 (11.28%)<br />cpp:           3846 (2.55%)<br />sh:            2108 (1.40%)<br />objc:           925 (0.61%)<br />python:         216 (0.14%)<br />pascal:         179 (0.12%)<br />perl:            29 (0.02%)</p><p>Total Physical Source Lines of Code (SLOC)                = 150,894<br />Development Effort Estimate, Person-Years (Person-Months) = 38.78 (465.39)<br /> (Basic COCOMO model, Person-Months = 2.4 * (KSLOC**1.05))<br />Schedule Estimate, Years (Months)                         = 2.15 (25.81)<br /> (Basic COCOMO model, Months = 2.5 * (person-months**0.38))<br />Estimated Average Number of Developers (Effort/Schedule)  = 18.03<br />Total Estimated Cost to Develop                           = $ 5,238,985<br /> (average salary = $56,286/year, overhead = 2.40).</p><p>4.3:</p><p>Totals grouped by language (dominant language first):<br />ansic:       128564 (84.12%)<br />asm:          17011 (11.13%)<br />cpp:           3800 (2.49%)<br />sh:            2108 (1.38%)<br />objc:           925 (0.61%)<br />python:         216 (0.14%)<br />pascal:         179 (0.12%)<br />perl:            29 (0.02%)</p><p>Total Physical Source Lines of Code (SLOC)                = 152,832<br />Development Effort Estimate, Person-Years (Person-Months) = 39.31 (471.67)<br /> (Basic COCOMO model, Person-Months = 2.4 * (KSLOC**1.05))<br />Schedule Estimate, Years (Months)                         = 2.16 (25.94)<br /> (Basic COCOMO model, Months = 2.5 * (person-months**0.38))<br />Estimated Average Number of Developers (Effort/Schedule)  = 18.19<br />Total Estimated Cost to Develop                           = $ 5,309,659<br /> (average salary = $56,286/year, overhead = 2.40).</p><p>So, Allegro costs around $5,300,000. Not too bad for a ten year old thingie <img src="http://www.allegro.cc/forums/smileys/smiley.gif" alt=":)" />
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (HoHo)</author>
		<pubDate>Thu, 22 Dec 2005 03:41:53 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
Total Estimated Cost to Develop = $ 5,309,659
</p></div></div><p>

See what you loose ! ;-X
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (GullRaDriel)</author>
		<pubDate>Thu, 22 Dec 2005 03:44:29 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
Total Estimated Cost to Develop = $ 5,309,659<br />(average salary = $56,286/year, overhead = 2.40).
</p></div></div><p>
Well done, Hoho! Now noone will work on Allegro anymore without being paid:P
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Murat AYIK)</author>
		<pubDate>Thu, 22 Dec 2005 03:47:54 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>I think the effort estimate is a <i>little</i> off. I doubt combining all developers together would make four full-time developers over ten years.<br />of course there is always the chance that allegro developers are simply so good they can do the work of a ten devs in 1/10&#39;th of the time <img src="http://www.allegro.cc/forums/smileys/grin.gif" alt=";D" />
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (HoHo)</author>
		<pubDate>Thu, 22 Dec 2005 03:49:00 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
pascal: 179 (0.12%)
</p></div></div><p>
Eh? <img src="http://www.allegro.cc/forums/smileys/huh.gif" alt="???" />
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Evert)</author>
		<pubDate>Thu, 22 Dec 2005 03:54:33 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="source-code snippet"><div class="inner"><pre>hoho@box ~<span class="k3">/</span>katsepolygon<span class="k3">/</span>allegro-svn $  sloccount <span class="k3">-</span><span class="k3">-</span>details .<span class="k3">/</span><span class="n">4</span>.<span class="n">3</span><span class="k3">/</span> <span class="k3">|</span> grep pascal
<span class="n">74</span>      pascal  src_amd64       <span class="k3">/</span>home<span class="k3">/</span>hoho<span class="k3">/</span>katsepolygon<span class="k3">/</span>allegro-svn<span class="k3">/</span><span class="n">4</span>.<span class="n">3</span><span class="k3">/</span>src<span class="k3">/</span>amd64<span class="k3">/</span>asmdefs.inc
<span class="n">105</span>     pascal  src_ppc <span class="k3">/</span>home<span class="k3">/</span>hoho<span class="k3">/</span>katsepolygon<span class="k3">/</span>allegro-svn<span class="k3">/</span><span class="n">4</span>.<span class="n">3</span><span class="k3">/</span>src<span class="k3">/</span>ppc<span class="k3">/</span>ppcdef.inc
</pre></div></div><p>

I think it doesn&#39;t use anything else but file extensions to see what language is used.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (HoHo)</author>
		<pubDate>Thu, 22 Dec 2005 04:11:26 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
I think the effort estimate is a little off. I doubt combining all developers together would make four full-time developers over ten years.
</p></div></div><p>
It looks like it thinks it was made in 2.16 years, which makes sense since allegro is developed rather slowly compared to commercial products.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (ImLeftFooted)</author>
		<pubDate>Thu, 22 Dec 2005 05:16:18 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
It looks like it thinks it was made in 2.16 years
</p></div></div><p>... by 18.19 developers <img src="http://www.allegro.cc/forums/smileys/smiley.gif" alt=":)" />
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (HoHo)</author>
		<pubDate>Thu, 22 Dec 2005 05:25:28 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="source-code"><div class="toolbar"></div><div class="inner"><table width="100%"><tbody><tr><td class="number">1</td><td><span class="p">#include &lt;allegro.h&gt;</span></td></tr><tr><td class="number">2</td><td>&#160;</td></tr><tr><td class="number">3</td><td><span class="k1">int</span> main<span class="k2">(</span><span class="k1">int</span> argc, <span class="k1">char</span><span class="k3">*</span> argv<span class="k2">[</span><span class="k2">]</span><span class="k2">)</span> <span class="k2">{</span></td></tr><tr><td class="number">4</td><td>  <a href="http://www.allegro.cc/manual/allegro_init" target="_blank"><span class="a">allegro_init</span></a><span class="k2">(</span><span class="k2">)</span><span class="k2">;</span></td></tr><tr><td class="number">5</td><td>  <span class="k1">int</span> lines <span class="k3">=</span> <span class="n">0</span><span class="k2">;</span></td></tr><tr><td class="number">6</td><td>&#160;</td></tr><tr><td class="number">7</td><td>  <span class="k1">if</span> <span class="k2">(</span>argc <span class="k3">&lt;</span> <span class="n">2</span><span class="k2">)</span></td></tr><tr><td class="number">8</td><td>    <span class="k1">return</span> <span class="k3">-</span><span class="n">1</span><span class="k2">;</span></td></tr><tr><td class="number">9</td><td>&#160;</td></tr><tr><td class="number">10</td><td>  <a href="http://www.allegro.cc/manual/PACKFILE" target="_blank"><span class="a">PACKFILE</span></a><span class="k3">*</span> f <span class="k3">=</span> <a href="http://www.allegro.cc/manual/pack_fopen" target="_blank"><span class="a">pack_fopen</span></a><span class="k2">(</span>argv<span class="k2">[</span><span class="n">1</span><span class="k2">]</span>, <span class="s">"rb"</span><span class="k2">)</span><span class="k2">;</span></td></tr><tr><td class="number">11</td><td>&#160;</td></tr><tr><td class="number">12</td><td>  <span class="k1">if</span> <span class="k2">(</span><span class="k3">!</span>f<span class="k2">)</span></td></tr><tr><td class="number">13</td><td>    <span class="k1">return</span> <span class="k3">-</span><span class="n">2</span><span class="k2">;</span></td></tr><tr><td class="number">14</td><td>&#160;</td></tr><tr><td class="number">15</td><td>  <span class="k1">while</span> <span class="k2">(</span><span class="k3">!</span>pack_eof<span class="k2">(</span>f<span class="k2">)</span><span class="k2">)</span> <span class="k2">{</span></td></tr><tr><td class="number">16</td><td>    <span class="k1">char</span> c <span class="k3">=</span> <a href="http://www.allegro.cc/manual/pack_getc" target="_blank"><span class="a">pack_getc</span></a><span class="k2">(</span>f<span class="k2">)</span><span class="k2">;</span></td></tr><tr><td class="number">17</td><td>    <span class="k1">if</span> <span class="k2">(</span>c <span class="k3">=</span><span class="k3">=</span> <span class="s">'\n'</span><span class="k2">)</span></td></tr><tr><td class="number">18</td><td>      <span class="k3">+</span><span class="k3">+</span>lines<span class="k2">;</span></td></tr><tr><td class="number">19</td><td>  <span class="k2">}</span></td></tr><tr><td class="number">20</td><td>  <a href="http://www.delorie.com/djgpp/doc/libc/libc_624.html" target="_blank">printf</a><span class="k2">(</span><span class="s">"%s: %i lines.\n"</span>, argv<span class="k2">[</span><span class="n">1</span><span class="k2">]</span>, lines<span class="k2">)</span><span class="k2">;</span></td></tr><tr><td class="number">21</td><td>&#160;</td></tr><tr><td class="number">22</td><td>  <span class="k1">return</span> <span class="n">0</span><span class="k2">;</span></td></tr><tr><td class="number">23</td><td><span class="k2">}</span></td></tr><tr><td class="number">24</td><td><a href="http://www.allegro.cc/manual/END_OF_MAIN" target="_blank"><span class="a">END_OF_MAIN</span></a><span class="k2">(</span><span class="k2">)</span></td></tr></tbody></table></div></div><p>
<img src="http://www.allegro.cc/forums/smileys/tongue.gif" alt=":P" />
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Tobias Dammers)</author>
		<pubDate>Thu, 22 Dec 2005 23:47:55 +0000</pubDate>
	</item>
</rss>
