16
I’m on my machine and want to upload the files on my local machine to my repository on github with..
I’ve already executed the commands git add
, git commit
and all that remains is to raise them. When I execute git remote -v
, returns the following:
$ git remote -v
origin [email protected]:romulosousa27/php.git (fetch)
origin [email protected]:romulosousa27/php.git (push)
otigin git.github.com:romulosousa27/php.git (fetch)
otigin git.github.com:romulosousa27/php.git (push)
teste https://github.com/romulosousa27 (fetch)
teste https://github.com/romulosousa27 (push)
At that point, he’s already prepared for the push
?
If yes , when I execute the command git push
, this is returned:
$ git push
fatal: The current branch master has no upstream branch.
To push the current branch and set the remote as upstream, use
git push --set-upstream origin master
P.S: My Key SSH
is already configured.
$ git push --set-upstream origin master ERROR: Repository not found. fatal: Could not read from remote Repository. Please make sure you have the correct access Rights and the Repository exists.
– Romulo Sousa
This github.com/romulosousa27/php.git repository doesn’t really exist. I checked with github and couldn’t find it. Did you leave it private? If yes, check the permissions in the project to clone/push.
– Giuliana Bezerra
Actually it doesn’t exist, I figured when I push it it would create a default repository... I used the github interface and thought it was the same principle, so I have to create a repository, clone and commission it?
– Romulo Sousa
That’s right, you need to create the project on github and then you associate your local project directory with the remote project using git remote add. As soon as you create it shows a page with the necessary commands to associate an existing local project to the remote.
– Giuliana Bezerra
Pow Uiliana worked out here, was just create the same repository. Thanks even, you made a child happy today hehe
– Romulo Sousa