From 9813be37abd1bfc065ace11ccec75545d82a0b23 Mon Sep 17 00:00:00 2001 From: "P. Taylor Goetz" Date: Fri, 13 Sep 2024 20:00:26 -0400 Subject: [PATCH] set initial branch name --- internal/git/git.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/git/git.go b/internal/git/git.go index e4b5a37..96e7d05 100644 --- a/internal/git/git.go +++ b/internal/git/git.go @@ -47,7 +47,7 @@ func HasPendingChanges(dirPath string) (bool, error) { // InitializeGitRepo initializes a new Git repository in the specified directory path. func InitializeGitRepo(dirPath string) error { - _, _, err := runGitCommand(dirPath, "init") + _, _, err := runGitCommand(dirPath, "init", "--initial-branch=main") if err != nil { return fmt.Errorf("failed to initialize git repository: %w", err) }