Skip to content

Error when i tried running command "git init -b main" saying "unknown switch b" #534

Answered by alymurtazamemon
Benrockiee asked this question in Q&A
Discussion options

You must be logged in to vote

@Benrockiee Patric wanted us to create the initial branch name as the main that is why -b main is added with git init.

You can do this also:

git init

After that

git branch -M main

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
1 reply
@Benrockiee
Comment options

Comment options

You must be logged in to vote
1 reply
@Benrockiee
Comment options

Answer selected by Benrockiee
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants