* [PATCH] Linux kernel contribution count script
@ 2012-09-06 6:17 Namhyung Kim
2012-09-06 6:23 ` Namhyung Kim
0 siblings, 1 reply; 2+ messages in thread
From: Namhyung Kim @ 2012-09-06 6:17 UTC (permalink / raw)
To: Minchan Kim; +Cc: LKML, Namhyung Kim
From: Namhyung Kim <namhyung.kim@lge.com>
$ ./contrib-count.sh
Usage: ./contrib-count.sh <Name> [ <Year> ]
$ ./contrib-count.sh Namhyung
Signed-off: 125
Reviewed: 3
Acked: 1
Tested: 0
$ ./contrib-count.sh Minchan 2012
Signed-off: 20
Reviewed: 32
Acked: 10
Tested: 1
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
---
contrib-count.sh | 27 +++++++++++++++++++++++++++
1 file changed, 27 insertions(+)
create mode 100755 contrib-count.sh
diff --git a/contrib-count.sh b/contrib-count.sh
new file mode 100755
index 000000000000..4d246db5735d
--- /dev/null
+++ b/contrib-count.sh
@@ -0,0 +1,27 @@
+#!/bin/sh
+#
+# Linux kernel contiribution counter.
+# It actually can be used on any git-managed projects.
+#
+
+if [ $# -eq 0 ]; then
+ echo "Usage: $0 <Name> [ <Year> ]"
+ exit 1
+fi
+
+NAME=$1
+
+# defaults to current year in YYYY format
+YEAR=$(date +"%Y")
+
+if [ $# -ge 2 ]; then
+ YEAR=$2
+fi
+
+for TAG in "Signed-off" "Reviewed" "Acked" "Tested";
+do
+ echo -n "$TAG: "
+ git log --grep="$TAG-by: $NAME" --since "$YEAR-01-01" --until "$YEAR-12-31" origin/master | \
+ git shortlog -sn | \
+ awk 'BEGIN { count = 0; } { count += $1; } END { print count; }'
+done
--
1.7.11.4
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] Linux kernel contribution count script
2012-09-06 6:17 [PATCH] Linux kernel contribution count script Namhyung Kim
@ 2012-09-06 6:23 ` Namhyung Kim
0 siblings, 0 replies; 2+ messages in thread
From: Namhyung Kim @ 2012-09-06 6:23 UTC (permalink / raw)
To: Minchan Kim; +Cc: LKML, Namhyung Kim
Ooops, Please forget about this.
It's intended for an internal use only :-/
Sorry for the noise.
Thanks,
Namhyung
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2012-09-06 6:31 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-09-06 6:17 [PATCH] Linux kernel contribution count script Namhyung Kim
2012-09-06 6:23 ` Namhyung Kim
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome