I've got a strange problem: tried to make a new repository, as usual, followed instructions from github:
- git init
- git add .
- git commit -m "first commit"
- git remote add origin https://github.com/*/**.git
- git push -u origin master
My problem occures at the 3rd step:
fatal: ambiguous argument 'HEAD': unknown revision or path not in the working tree. Use '--' to separate paths from revisions, like this: 'git [...] -- [...]' fatal: ambiguous argument 'HEAD': unknown revision or path not in the working tree. Use '--' to separate paths from revisions, like this: 'git [...] -- [...]' "Branch could not be empty."
What's the matter? I didn't have such problem until now. Tried to reinit git by deleting the folder and typing new "git init" command - the problem still the same.
p.s.: the full way of making repository I've passed: got to the github.com, clicked on the button "New" (repository), added a name for it (the same as a folder on PC) and started to do some magic via cmder (following the instructions from github) ...
p.p.s.: I use windows 10 and cmder (tried gitBash too).
upd: there's something in my windows environment, 'cause on another machine everything's fine.