git push origin feature refspec error

If you try to

git push -u origin feature/branch_name

and you get this error “error: src refspec feature/branch_name does not match any”, it means that your local branch are not named correctly. It should be named


as well, not just branch_name. Do a “git branch” to confirm yourself.

Author: bpeh

Bernard Peh is a great passioner of web technologies and one of the co-founder of Website Design and Reviews. He works with experienced web designers and developers everyday, developing and designing commercial websites. He specialises mainly in SEO and PHP programming.