This error I got from GitHub when I try to push my source code:
1 2 3 4 5 6 7 8 9 10 | [mythcat@desk django]$ git push -u origin master Username for 'https://github.com': catafest Password for 'https://catafest@github.com': To https://github.com/catafest/django_chart.git ! [rejected] master -> master (non-fast-forward) error: failed to push some refs to 'https://github.com/catafest/django_chart.git' hint: Updates were rejected because the tip of your current branch is behind hint: its remote counterpart. Integrate the remote changes (e.g. hint: 'git pull ...') before pushing again. hint: See the 'Note about fast-forwards' in 'git push --help' for details. |
You need to use the argument –force:
1 2 3 4 5 6 7 8 9 10 11 12 | [mythcat@desk django]$ git push --force origin master Username for 'https://github.com': catafest Password for 'https://catafest@github.com': Enumerating objects: 8690, done. Counting objects: 100% (8690/8690), done. Delta compression using up to 2 threads Compressing objects: 100% (5020/5020), done. Writing objects: 100% (8690/8690), 14.10 MiB | 744.00 KiB/s, done. Total 8690 (delta 2593), reused 8690 (delta 2593) remote: Resolving deltas: 100% (2593/2593), done. To https://github.com/catafest/django_chart.git + 998aaa4e...8c36d1f7 master -> master (forced update) |