[releng] add script to retrieve for multiple gnome releases



commit e99798dec3a4c4455a90284727f68a961c1d75c1
Author: Olav Vitters <olav vitters nl>
Date:   Mon Aug 20 15:32:28 2012 +0200

    add script to retrieve for multiple gnome releases

 tools/contributions/get-git-stats |    3 ++-
 tools/contributions/get-releases  |   15 +++++++++++++++
 tools/contributions/releases      |    1 -
 3 files changed, 17 insertions(+), 2 deletions(-)
---
diff --git a/tools/contributions/get-git-stats b/tools/contributions/get-git-stats
index 6248b55..dfccb3f 100755
--- a/tools/contributions/get-git-stats
+++ b/tools/contributions/get-git-stats
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
 # vim: set ts=4 sw=4:
 
 if [ -z "$1" ]; then
@@ -38,6 +38,7 @@ for d in ~/src/* /git/*.git /git/archive/*.git; do
 	git config --get hooks.mailinglist | grep -q gnome || continue
 
 	module=$(basename "$d")
+	module="${module%.git}"
 
 	# Total number of commits:
 	commits=$(git log --after="$SINCE" --until="$UNTIL" --pretty=oneline | wc -l)
diff --git a/tools/contributions/get-releases b/tools/contributions/get-releases
new file mode 100755
index 0000000..c295b8f
--- /dev/null
+++ b/tools/contributions/get-releases
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+while read release date; do
+	SINCE="$UNTIL"
+	UNTIL="$date"
+	[ -z "$SINCE" ] && continue
+	[ -z "$release" ] && continue
+
+	mkdir -p "./$release"
+	cd "./$release"
+
+	../get-git-stats "$SINCE" "$UNTIL" | tee modules.csv
+	cd ..
+done < releases
+
diff --git a/tools/contributions/releases b/tools/contributions/releases
index 817cbba..539ba1f 100644
--- a/tools/contributions/releases
+++ b/tools/contributions/releases
@@ -18,4 +18,3 @@
 3.0.0	2011-04-06
 3.2.0	2011-09-28
 3.4.0	2012-04-18
-



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]