diff --git a/external/update_submodules.sh b/external/update_submodules.sh new file mode 100755 index 0000000..610f1d0 --- /dev/null +++ b/external/update_submodules.sh @@ -0,0 +1,13 @@ +#! /usr/bin/env bash + +for dir in * ; do + dir=${dir%*/} + if [ -d "${dir}" ]; then + echo "${dir}" + cd "${dir}" + latest_commit_with_tag=`git rev-list --tags --max-count=1` + latest_tag=`git describe --tags ${latest_commit_with_tag}` + git checkout "${latest_tag}" + cd .. + fi +done