So ive been trying to move my android studio project into a git repo however i keep getting errors when following the tutorial below. the error I am getting is the following code below.
I can't find a fix for this but I've been stuck on this for hours, any help very welcome.
My error:
$ git push -u origin main
To <repo url>
! [rejected] main -> main (fetch first)
error: failed to push some refs to <repo url>
hint: Updates were rejected because the remote contains work that you do
hint: not have locally. This is usually caused by another repository pushing
hint: to the same ref. You may want to first integrate the remote changes
hint: (e.g., 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.