From 0f25834017ca158fa1f431503d1ab077107a3b94 Mon Sep 17 00:00:00 2001 From: Eemeli Palotie Date: Mon, 13 Nov 2023 16:05:17 +0200 Subject: [PATCH] test: Explicitly use master branch in git init (#89) --- packages/nx-semantic-release/src/tests/setup-test-repo.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/nx-semantic-release/src/tests/setup-test-repo.ts b/packages/nx-semantic-release/src/tests/setup-test-repo.ts index e2cc0444..b0a57d7b 100644 --- a/packages/nx-semantic-release/src/tests/setup-test-repo.ts +++ b/packages/nx-semantic-release/src/tests/setup-test-repo.ts @@ -36,7 +36,7 @@ async function setupRemoteRepo() { fs.mkdirSync(remoteReposDirectory, { recursive: true }); } - await exec(`git init --bare project.git`, { + await exec(`git init --bare project.git -b master`, { cwd: remoteReposDirectory, }); } @@ -54,7 +54,7 @@ async function initGit() { await setupRemoteRepo(); await runCommandsInTestProj([ - 'git init', + 'git init -b master', 'git config user.email "test@example.com"', 'git config user.name "Test"', 'git add .',