From 2192fd2099fa52d8b5b18c5d4221644e39f669da Mon Sep 17 00:00:00 2001 From: Tanguy Pruvot Date: Wed, 6 Jun 2012 21:39:23 +0200 Subject: env: implement the repodiff command sample usage: repodiff ics repodiff github/ics --numstat repodiff android-4.0.4_r1.2 android-4.0.4_r2 Change-Id: Id1c1e504c75676707e59f051fd5ff9ce748d4297 Signed-off-by: Tanguy Pruvot --- envsetup.sh | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'envsetup.sh') diff --git a/envsetup.sh b/envsetup.sh index 23d4bcf..c02dae7 100644 --- a/envsetup.sh +++ b/envsetup.sh @@ -1868,6 +1868,16 @@ function reposync() { ;; esac } + +function repodiff() { + if [ -z "$*" ]; then + echo "Usage: repodiff [[ref-to] [--numstat]]" + return + fi + diffopts=$* repo forall -c \ + 'echo "$REPO_PATH ($REPO_REMOTE)"; git diff ${diffopts} 2>/dev/null ;' +} + # Force JAVA_HOME to point to java 1.7 or java 1.6 if it isn't already set. # # Note that the MacOS path for java 1.7 includes a minor revision number (sigh). -- cgit v1.1