Git reference broken


I get this error when i try to push:

rror: update_ref failed for ref ‘refs/remotes/origin/master’: cannot lock ref ‘refs/remotes/origin/master’: unable to resolve reference ‘refs/remotes/origin/master’: reference broken
Everything up-to-date

and this messege when i try git status or git commit:

On branch master
Your branch is based on ‘origin/master’, but the upstream is gone.
(use “git branch --unset-upstream” to fixup)

what could i do to fix this?


Have you tried, clone, copy, add, commit, and push?