summaryrefslogtreecommitdiffstats
path: root/envsetup.sh
diff options
context:
space:
mode:
authorTanguy Pruvot <tanguy.pruvot@gmail.com>2012-06-06 21:39:23 +0200
committerAdnan Begovic <adnan@cyngn.com>2015-10-06 16:11:58 -0700
commit2192fd2099fa52d8b5b18c5d4221644e39f669da (patch)
tree9ad3e4f3f4759a4f660c51f25e912958bd561af0 /envsetup.sh
parent59b2aee7708e0561673291872a4bf480c3a33af2 (diff)
downloadbuild-2192fd2099fa52d8b5b18c5d4221644e39f669da.zip
build-2192fd2099fa52d8b5b18c5d4221644e39f669da.tar.gz
build-2192fd2099fa52d8b5b18c5d4221644e39f669da.tar.bz2
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 <tanguy.pruvot@gmail.com>
Diffstat (limited to 'envsetup.sh')
-rw-r--r--envsetup.sh10
1 files changed, 10 insertions, 0 deletions
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-from> [[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).