Side note: We also want to call this from git submodule update Signed-off-by: Stefan Beller <[email protected]> --- submodule.c | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/submodule.c b/submodule.c
index 4e74e38829..66651ffa34 100644
--- a/submodule.c
+++ b/submodule.c
@@ -1483,6 +1483,8 @@ int submodule_move_head(const char *path,
ret = -1;
goto out;
}
+
+ reattach_HEAD(path, 0);
} else {
struct strbuf sb = STRBUF_INIT;
--
2.13.0.rc1.1.gbc33f0f778

