Skip to content

feat(git)!: default new repos to main and make branch aliases branch-agnostic - #47

Merged
sha1n merged 4 commits into
masterfrom
feat/git-trunk-aliases
Oct 1, 2026
Merged

sha1n merged 4 commits into
masterfrom
feat/git-trunk-aliases

Conversation

@sha1n

@sha1n sha1n commented Oct 1, 2026

Copy link
Copy Markdown
Owner

Summary

New repositories now start on main. The aliases that worked only with master now find the default branch of each repository at run time, so they work with main, master or any other name.

Changes

  • Set init.defaultBranch to main and replace master, pull_master, pullmr with trunk, pull_trunk, pullt.
  • Print git helper errors to stderr, so trunk aliases and wt no longer fail silently.

Review notes

  • Breaking: the master, pull_master and pullmr aliases are removed.
  • The aliases read origin/HEAD, then local main, then local master; other names need git remote set-head origin --auto.

🤖 Generated with Claude Code

sha1n and others added 4 commits October 1, 2026 08:29
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…agnostic

init.defaultBranch is now main. The trunk aliases find the default branch
at run time from origin/HEAD, then the local main, then the local master,
and do not run git when they cannot find it.

BREAKING CHANGE: the master, pull_master and pullmr aliases are removed.
Use trunk, pull_trunk and pullt.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@sha1n sha1n added the enhancement New feature or request label Oct 1, 2026
@sha1n sha1n self-assigned this Oct 1, 2026
@sha1n
sha1n merged commit 578157a into master Oct 1, 2026
2 checks passed
@sha1n
sha1n deleted the feat/git-trunk-aliases branch October 1, 2026 06:25
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.

1 participant