Hi every one, am kindly requesting for your assistance, i successfully push to a remote branch on my account for the first time( first push where i use git push origin <name of the branch>) but when am pushing the second or any other time except the first i normally get an error $ git push Enter passphrase for key '/c/Users/kaweesi joseph/.ssh/id_rsa': error: src refspec refs/heads/TRUNK-3814:g...@github.com does not match any. error: failed to push some refs to 'g...@github.com:k-joseph/openmrs-core.git' i have also tried using git push --all and i get $ git push --all Enter passphrase for key '/c/Users/kaweesi joseph/.ssh/id_rsa': Counting objects: 249, done. Delta compression using up to 4 threads. Compressing objects: 100% (79/79), done. Writing objects: 100% (139/139), 24.36 KiB, done. Total 139 (delta 72), reused 99 (delta 45) To g...@github.com:k-joseph/openmrs-core.git 9b76cd3..9e4ba80 TRUNK-3814 -> TRUNK-3814 * [new branch] TRUNK-2449 -> TRUNK-2449 * [new branch] testing -> testing ! [rejected] master -> master (non-fast-forward) error: failed to push some refs to 'g...@github.com:k-joseph/openmrs-core.git' hint: Updates were rejected because a pushed branch tip is behind its remote hint: counterpart. Check out this branch and merge the remote changes hint: (e.g. 'git pull') before pushing again. hint: See the 'Note about fast-forwards' in 'git push --help' for details.
So i have always been deleting the remote branch in order to succeed in pushing my changes to a remote branch, i fill this is not the best way to do this Please help me with a git command that i can use to push to a remote branch the second, third or even more time without first deleting the remote branch, thanks all --