Skip to content

Instantly share code, notes, and snippets.

@uggedal
Created March 12, 2015 08:54
Show Gist options
  • Save uggedal/20225be7e1610be1b70f to your computer and use it in GitHub Desktop.
Save uggedal/20225be7e1610be1b70f to your computer and use it in GitHub Desktop.
android-tools update check
#!/bin/sh
repos='system/core system/extras external/libselinux external/f2fs-tools'
[ $# -eq 2 ] || exit 1
from=android-$1
to=android-$2
for r in $repos; do
if ! [ -d "$(basename $r)/.git" ]; then
git clone https://android.googlesource.com/platform/$r
else
(
cd $(basename $r)
git fetch
)
fi
done
d() {
git diff ${from}..${to} -- "$@"
}
(
cd core
d adb fastboot libcutils libzipfile libsparse
)
(
cd extras
d ext4_utils f2fs_utils
)
(
cd libselinux
d src
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment