Skip to content

Instantly share code, notes, and snippets.

@bbasata
Last active August 29, 2015 14:19
Show Gist options
  • Save bbasata/5c5ec40650371e62e970 to your computer and use it in GitHub Desktop.
Save bbasata/5c5ec40650371e62e970 to your computer and use it in GitHub Desktop.
twitter-pairing with @magnusstahre
SUBMODULE=lib/ansible/modules/core
SUBMODULE_COMMIT=4d9ce9cf2cdee14b1c417e92059d4ef83dbcc457
for superproject_tag in $(git tag); do
git ls-tree -r $superproject_tag | grep $SUBMODULE | awk '{ print $3 }' | while read submodule_commit_in_superproject_tag; do
(cd $SUBMODULE && git rev-list $submodule_commit_in_superproject_tag | grep $SUBMODULE_COMMIT >/dev/null && echo "Found submodule commit in superproject tag $superproject_tag")
done
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment