git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Graph sloc tool for git repos

From
KHKai Hendry <hendry@iki.fi>
Date
Mar 12, 2016, 11:00 UTC
Message-ID
<1457780426.2632189.547083938.25305E83@webmail.messagingengine.com>
Hi there,

I penned a script to plot SLOC of a git project using GNUplot & I thought the fastest way to count code fluctuations was via `git show --numstat`.

However that requires some awk counting of the lines: https://github.com/kaihendry/graphsloc/blob/5f31e388e9b655e1801f13885f4311d221663a19/collect-stats.sh#L32

Is there a better way I missed? I think there is bug since my graph was a factor of 10 out whilst graphing Linux: https://twitter.com/kaihendry/status/706627679924174848

(Though the shape looks right)

Good news it's generating graphs for smaller projects just fine: http://s.natalian.org/2016-03-12/dwm-3465bed.csv.svg

Anyway, would love to get your feedback on https://github.com/kaihendry/graphsloc

Kind regards from Petaling Jaya,
Next: Jeff King
Message 1 of 3 in “Graph sloc tool for git repos”
  1. Kai HendryMar 12, 2016
  2. Jeff KingMar 14, 2016
  3. Jeff KingMar 14, 2016

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.