From 3f06d9b5a0fcad823f2a32774546925884e5c2fa Mon Sep 17 00:00:00 2001 From: David Taylor Date: Tue, 6 Dec 2016 14:34:22 +0000 Subject: [PATCH] githooks: just update submodule on ref changes with deps now managed by the scm directly (the vendor submodule), we don't need to run glock or make during scm operations --- githooks/post-checkout | 6 +++--- githooks/post-merge | 4 +--- githooks/post-rewrite | 4 +--- 3 files changed, 5 insertions(+), 9 deletions(-) diff --git a/githooks/post-checkout b/githooks/post-checkout index 499c13861858..993486d0b3e3 100755 --- a/githooks/post-checkout +++ b/githooks/post-checkout @@ -1,6 +1,6 @@ #!/usr/bin/env bash set -e -[[ ! $GIT_REFLOG_ACTION =~ pull[[:space:]]+--rebase ]] && exit 0 - -make .bootstrap +if [ "$1" != "$2" ]; then # previous ref != new ref. + exec git submodule update --init +fi diff --git a/githooks/post-merge b/githooks/post-merge index e006ae62e2d1..d7d7bbecf584 100755 --- a/githooks/post-merge +++ b/githooks/post-merge @@ -1,6 +1,4 @@ #!/usr/bin/env bash set -e -[[ ! $GIT_REFLOG_ACTION =~ pull ]] && exit 0 - -make .bootstrap +exec git submodule update --init diff --git a/githooks/post-rewrite b/githooks/post-rewrite index 537204e27804..d13de4d297a9 100755 --- a/githooks/post-rewrite +++ b/githooks/post-rewrite @@ -1,6 +1,4 @@ #!/usr/bin/env bash set -e -[[ ! $GIT_REFLOG_ACTION =~ rebase ]] && exit 0 - -make .bootstrap +# TODO(dt): do we want to submomdule update here?