If you are on a detached head and you want to push to your remote branch
git push origin HEAD:name-of-your-branch
otherwise you can create a new branch and push to it ( it will be created automatically )
git branch new-branch-name
git push -u origin new-branch-name
More Related Contents:
- Is there a way to cache https credentials for pushing commits?
- Git push error ‘[remote rejected] master -> master (branch is currently checked out)’
- Git push requires username and password
- Default behavior of “git push” without a branch specified
- How do I properly force a Git push?
- Undoing a ‘git push’
- How to push to a non-bare Git repository?
- How can I recover from an erronous git push -f origin master?
- git push –force-with-lease vs. –force
- How can I automatically push after committing in Git?
- Can’t push to GitHub because of large file which I already deleted
- What are the differences between “git commit” and “git push”?
- Git Push ERROR: Repository not found
- ! [rejected] master -> master (fetch first)
- Remote origin already exists on ‘git push’ to a new repository
- Github remote push pack size exceeded
- Git – What is the difference between push.default “matching” and “simple”
- Git push hangs when pushing to Github?
- How to push a local Git repository to another computer?
- Heroku: How to push different local Git branches to Heroku/master
- Issue pushing new code in Github
- What does ‘–set-upstream’ do?
- Is there a way in git to obtain a push date for a given commit?
- Pushing from local repository to GitHub hosted remote
- git push heroku master says “Everything up-to-date”, but the app is not current
- How do I fix “remote: fatal error in commit_refs” errors trying to push with Git?
- Git: which is the default configured remote for branch?
- How can I prevent non-fastforward pushes to selected branch(es) in git?
- When should I use “git push –force-if-includes”
- How to push different local Git branches to Heroku/master