From ae3e868ae22f59a1cd5871bdb90ae933c338b359 Mon Sep 17 00:00:00 2001 From: Rhys Arkins <rhys@arkins.net> Date: Mon, 5 Jul 2021 07:28:05 +0200 Subject: [PATCH] fix(git): fetch to depth=5 (#10704) --- lib/util/git/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/util/git/index.ts b/lib/util/git/index.ts index a3f2a9fc49..125f077280 100644 --- a/lib/util/git/index.ts +++ b/lib/util/git/index.ts @@ -216,7 +216,7 @@ async function setBranchPrefix(branchPrefix: string): Promise<void> { logger.debug('Setting branchPrefix: ' + branchPrefix); const ref = `refs/heads/${branchPrefix}*:refs/remotes/origin/${branchPrefix}*`; try { - await git.fetch(['origin', ref, '--depth=2', '--force']); + await git.fetch(['origin', ref, '--depth=5', '--force']); } catch (err) /* istanbul ignore next */ { checkForPlatformFailure(err); throw err; -- GitLab