From ab42a919a561b8f47acd268816d614b5a2b172d8 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Mon, 15 Jun 2020 12:01:25 -0300 Subject: [PATCH] feat: recurse submodules Signed-off-by: Carlos Alexandro Becker --- pkg/buildcontext/git.go | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/pkg/buildcontext/git.go b/pkg/buildcontext/git.go index 18d6e2ded3..a9b715c031 100644 --- a/pkg/buildcontext/git.go +++ b/pkg/buildcontext/git.go @@ -50,9 +50,10 @@ func (g *Git) UnpackTarFromBuildContext() (string, error) { directory := constants.BuildContextDir parts := strings.Split(g.context, "#") options := git.CloneOptions{ - URL: getGitPullMethod() + "://" + parts[0], - Auth: getGitAuth(), - Progress: os.Stdout, + URL: getGitPullMethod() + "://" + parts[0], + Auth: getGitAuth(), + Progress: os.Stdout, + RecurseSubmodules: git.DefaultSubmoduleRecursionDepth, } if len(parts) > 1 { options.ReferenceName = plumbing.ReferenceName(parts[1])