gitfiti icon indicating copy to clipboard operation
gitfiti copied to clipboard

Fatal: invalid refspec 'master'?

Open filiptronicek opened this issue 4 years ago • 4 comments

It seems when I try to run the bash script in Ubuntu's Terminal, it creates the repo, but then fails at Fatal: invalid refspec 'master'?.

filiptronicek avatar Aug 30 '20 22:08 filiptronicek

Can you run git branch -a and post the result? The script probably needs the default branch name changed from "master" to "main".

gelstudios avatar Sep 01 '20 19:09 gelstudios

Screen Shot 2020-11-09 at 4 45 56 pm

  1. Im going trough the same problem, it keeps on showing fatal: couldn't find remote ref master
  2. When i ignored the warning and proceed with key, it got pushed to GitHub but i have waited for 3-4 days but nothing showing up. Been trying multiple times with different repo too.

git branch -a showing me as above screenshot. Is there any problem with my git ? Thanks for your help !

syd-developer avatar Nov 09 '20 08:11 syd-developer

It turns out that the local git default is still "master", so the git branch -a output is right.

Github is now using "main" as the default base branch for new repositories, so gitfiti has been updated to use the new default.

I also moved this repo's base branch to main.

If you run into similar issues, deleting the target repo and re-creating it on github should make it work.

gelstudios avatar Dec 09 '20 23:12 gelstudios

@grabtheskills it looks like your error was different, and is likely an auth problem. [email protected]: Permission denied (publickey).

you could try deleting the target repo from github and created it again. you might also want to make sure your name / email as displayed in git config -l match your github profile, or the commits / pixels wont be attributed to your profile.

gelstudios avatar Dec 13 '20 07:12 gelstudios