I keep getting an error saying: rejected master-> master (fetch first), failed to push some refs.... because remote contains work you do not have locally.
I just want git to overwrite the files currently in the repository with the new uploads so I've been trying to use git push -u origin master, but this error keeps popping up. I'm brand new to git/github. Why is this happening?
I've tried to merge the existing files in the repo with the files on my desktop, but I keep getting merge conflicts. Not sure how to deal with these.
git telling you that you must first:
git fetch
and later
git add /commit /push
fetch is similar to pull but, pull merge the data in files in your local branch , fetch update only the branch structure and id..
if fetch does not work, it means that someone else committed to changing, and now your version must be upgraded before being released
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With