From 28d7ffc165a2454dabf79b312e950a785a9a01f3 Mon Sep 17 00:00:00 2001 From: shockrah Date: Sun, 6 Oct 2019 15:33:00 -0700 Subject: [PATCH] stats about code --- scripts/stats.sh | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 scripts/stats.sh diff --git a/scripts/stats.sh b/scripts/stats.sh new file mode 100644 index 0000000..2cb426e --- /dev/null +++ b/scripts/stats.sh @@ -0,0 +1,22 @@ +#!/bin/sh + +# Some basic Metrics about the project itself + +red= +green= +blue= +nc= + +c_code=`wc -l *.c *.h | tail -1 | awk '{print $1}'` +s_code=`wc -l *.s | tail -1 | awk '{print $1}'` +m_code=`wc -l makefile link.ld bochsrc.conf | tail -1 | awk '{print $1}'` +sh_code=`wc -l scripts/*.sh | tail -1 | awk '{print $1}'` + +echo C $c_code > stats.dat +echo ASM $s_code >> stats.dat +echo Misc $m_code >> stats.dat +echo Shell $sh_code >> stats.dat + +termgraph stats.dat --color blue --title "Language Usage" + +rm -f stats.dat