aboutsummaryrefslogtreecommitdiff
path: root/bin/post-update
diff options
context:
space:
mode:
authorArquivo Publico de Memoria Coletiva <arquivo@sarava.org>2015-08-09 16:34:28 -0300
committerArquivo Publico de Memoria Coletiva <arquivo@sarava.org>2015-08-09 16:34:28 -0300
commitc00d1400ca336bbf763ecfd02c8108c44b6c0da7 (patch)
tree5e8dbbf5f48d719162535623524bc23c5ce3114e /bin/post-update
parent7181066db9daab1e561cc3adcaa81a85216dfb93 (diff)
downloadarquivo-c00d1400ca336bbf763ecfd02c8108c44b6c0da7.tar.gz
arquivo-c00d1400ca336bbf763ecfd02c8108c44b6c0da7.tar.bz2
Git hook: recursive submodule init/update
Diffstat (limited to 'bin/post-update')
-rwxr-xr-xbin/post-update10
1 files changed, 9 insertions, 1 deletions
diff --git a/bin/post-update b/bin/post-update
index 3098dab92fa..48a6a16cb27 100755
--- a/bin/post-update
+++ b/bin/post-update
@@ -2,7 +2,15 @@
cd ..
unset GIT_DIR
-git annex sync
+
+if [ -d ".git/annex" ]; then
+ git annex sync
+else
+ git reset HEAD
+ git checkout -f
+fi
+
+git submodule update --init --recursive
cd -
exec git update-server-info