I created a remote repo then create a local one locally:
git init
then added the files i need using git add
then git commit -m "something"
finally git push origin master
I got this error fatal:
'origin' does not appear to be a git repository
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
should i like the remote and local in some command or something? and if so is it ok if i already added and commited or should i start over locally?
EDIT:
Apparently i should add git remote add origin ssh://git@example.com:1234/myRepo.git
but what should i replace that ssh with as in where can i find my version of what i should add.
Got this error :
! [rejected] master -> master (fetch first)
error: failed to push some refs to
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.