Skip to content

feat(init): respect git config init.defaultBranch setting #61

Merged
avihut merged 1 commit intodevelopfrom
claude/daft-default-branch-2b36v
Jan 23, 2026
Merged

feat(init): respect git config init.defaultBranch setting #61
avihut merged 1 commit intodevelopfrom
claude/daft-default-branch-2b36v

Conversation

@avihut
Copy link
Owner

@avihut avihut commented Jan 23, 2026

No description provided.

The git-worktree-init command now queries git config init.defaultBranch
(global) when no -b/--initial-branch option is provided. Falls back to
"master" if the config is not set.

Priority order:
1. Explicitly provided via -b/--initial-branch
2. Git config init.defaultBranch (global)
3. Fallback to "master"
@avihut avihut changed the base branch from master to develop January 23, 2026 06:56
@avihut avihut changed the title ci: trigger canary workflow feat(init): respect git config init.defaultBranch setting Jan 23, 2026
@avihut avihut merged commit b040069 into develop Jan 23, 2026
@avihut avihut deleted the claude/daft-default-branch-2b36v branch January 23, 2026 08:29
@avihut avihut self-assigned this Jan 23, 2026
@avihut avihut added the enhancement New feature or request label Jan 23, 2026
@avihut avihut added this to the v1.0.0 milestone Jan 23, 2026
avihut added a commit that referenced this pull request Jan 24, 2026
The git-worktree-init command now queries git config init.defaultBranch
(global) when no -b/--initial-branch option is provided. Falls back to
"master" if the config is not set.

Priority order:
1. Explicitly provided via -b/--initial-branch
2. Git config init.defaultBranch (global)
3. Fallback to "master"

Co-authored-by: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants