Page 1 of 2 12 LastLast
Results 1 to 10 of 11

Thread: Useful little program (maybe)

  1. #1
    PGD Community Manager AthenaOfDelphi's Avatar
    Join Date
    Dec 2004
    Location
    South Wales, UK
    Posts
    1,245
    Blog Entries
    2

    Useful little program (maybe)

    Ever wondered how many lines of Pascal reside in all the .pas files on your machine? No I'm shocked... I lie awake at night pondering that very thought ;-)

    Just kidding of course, but I was wondering how many lines of code are in a new system I'm writing as its the first big PHP project I've worked on. I tried to find a program to count the number of lines on-line, but couldn't find one that didn't cost money.

    So I wrote a simple one... its real high tech ;-) And wouldn't you know, while waiting for it to scan one of my drives, I found a free one on-line... typical :-)

    Anyhow, if anyone has need of a simple line counting program, you are more than welcome to use it. Its available on my blog here.
    :: AthenaOfDelphi :: My Blog :: My Software ::

  2. #2
    Legendary Member cairnswm's Avatar
    Join Date
    Nov 2002
    Location
    Randburg, South Africa
    Posts
    1,537

    Useful little program (maybe)

    My game dev directory counts 320937 lines of Pascal code :shock:

    Talk about being verbose!
    William Cairns
    My Games: http://www.cairnsgames.co.za (Currently very inactive)
    MyOnline Games: http://TheGameDeveloper.co.za (Currently very inactive)

  3. #3

    Useful little program (maybe)

    Using BDS I have a hidden directory "History" in every projects directory where all changed files are backed up when saving the project. And not only once but change by change a new file is created, so you can get back older versions of your code easily.

    My question now:

    Do you factor this in your line counter? I mean, thats a lot of lines which are just "backups" of my real code...

    Greetings,
    Dirk
    <a href="http://www.greatgamesexperiment.com/game/Valgard/?utm_source=gge&amp;utm_medium=badge_game"><img border="0" alt="GGE" title="GGE" src="http://static.greatgamesexperiment.com/badge/game/valgard/gge400x56.png"></a>

  4. #4
    PGD Community Manager AthenaOfDelphi's Avatar
    Join Date
    Dec 2004
    Location
    South Wales, UK
    Posts
    1,245
    Blog Entries
    2

    Useful little program (maybe)

    In short Dirk, no I don't :-)

    It was a quick dirty little program to get the job done... if enough peeps ask for extra functionality, maybe I'll extend it :-) Maybe add a --bds switch that takes the versioning system into account ;-)

    I scanned my main work drive last night... 7890 .pas files containing a whopping 6.3Mil lines :-o That number was so big I had to double check the code to make sure it was working properly :-)
    :: AthenaOfDelphi :: My Blog :: My Software ::

  5. #5

    Useful little program (maybe)

    doesn't work, i run it in directory i want it to scan, and it just does nothing, i tried specifying directory and all and it just doesn't work.

    i tried:

    Code:
    lcount.exe "C&#58;\Documents and Settings\...\Delfi\*.pas" -subdir
    Code:
    lcount.exe *.pas -subdir
    This is my game project - Top Down City:
    http://www.pascalgamedevelopment.com...y-Topic-Reboot

    My OpenAL audio wrapper with Intelligent Source Manager to use unlimited:
    http://www.pascalgamedevelopment.com...source+manager

  6. #6
    PGD Community Manager AthenaOfDelphi's Avatar
    Join Date
    Dec 2004
    Location
    South Wales, UK
    Posts
    1,245
    Blog Entries
    2

    Useful little program (maybe)

    Hi Delfi,

    Thanks for the feedback :-)

    I didn't take into account long filenames enclosed in quote.... I can sense version 1.1 coming later today ;-)

    The switches like subdir, are linux style... you need two - characters before the switch, so your second example:-

    Code:
    lcount *.pas --subdir
    :: AthenaOfDelphi :: My Blog :: My Software ::

  7. #7

    Useful little program (maybe)

    Neat little utility, Athena.

    My current (trimmed down) delphi projects directory (always has been "C:\Delphi") is 39k lines. My old one has 113k lines. Not bad for an amateur.

  8. #8

    Useful little program (maybe)

    Well, I have 67,846 lines of code in the JumpStart core engine (That was a surprise), 481 lines of code in the lpr files, and 5,580 lines of script code for Secrets of the Domus Aurea.

    I must say, I was surprised to find out how much code is sitting behind my entry this year

  9. #9

    Useful little program (maybe)

    Some time ago I wrote a thing called "LOC-o-meter" to count my code lines. It's kinda primitive, I use it with the SendTo-Function of windows, marking all my code files and then send-to-ing them to LOC-o-meter.

    MechaChess currently consists of 7322 lines and 193572 bytes of code which is not as much as I hoped. My project is a little... suspended due to a lack of motivation, time, a XML-parser and models. Anyway, I should keep to the point.

  10. #10

    Useful little program (maybe)

    Looks like I already got 41057 lines of code in my entry.
    If you develop an idiot proof system, the nature develops better idiots.

Page 1 of 2 12 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •