Skip to content

Commit b5ab114

Browse files
committed
dockerhub: use post checkout hook for git submodule init
Signed-off-by: deadprogram <[email protected]>
1 parent 0a7e740 commit b5ab114

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

hooks/README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Hooks for Docker Hub
2+
3+
Files in this directory are custom commands to be run during the different Docker Hub build phases.
4+
5+
See https://docs.docker.com/docker-hub/builds/advanced/#custom-build-phase-hooks

hooks/post_checkout

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#!/bin/bash
2+
# Docker hub does a recursive clone, then checks the branch out,
3+
# so when a PR adds a submodule (or updates it), it fails.
4+
git submodule update --init

0 commit comments

Comments
 (0)