BUG: git log on bare repository fails if the default branch is not called master
- From
- Ian Molton <git-ian@mnementh.co.uk>
- Date
- Jun 3, 2022, 14:22 UTC
- Message-ID
- <a1830e79-9503-3fd9-8c50-a2856206e219@mnementh.co.uk>
Hi,
Please CC me in replies, I'm not on the list.
I've noticed that git log assumes the default branch is master, even if it doesn't exist...
My latest repo has it set to "mainline" and all was well until I pushed it to a bare repo on my server.
Expectation:
If I run
git log
in the bare repo, it should log the default (or only!) branch.
Reality:
git log # fatal: your current branch 'master' does not have any commits yet
-Ian