I am new to the git so please be patient with me :)
So I have created a repo in GitLab and I am trying to push the code into the repo.
Steps I used: 1. git clone [project URL]
git init
git remote add origin [project URL]
git add [folder name]
git commit -m [your message]
git push -u origin master
Now when i push the code i get this error
git push -u origin master
To [project URL]
! [rejected] master -> master (fetch first)
error: failed to push some refs to [project 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.
My repo :
My directory i wanna push to the repo: