Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Problems adding git remote repository

Tags:

git

I'm having problems adding a remote repository to my local one. I first tried using Tower where I manged to add my local repo, but when it came to adding a remote repo it just said add the URL. It doesn't say anything about this URL. Should it include ssh:// my username etc. etc.

So I found this article and followed it precisly, until it came to adding a remote repository. It failed. Can anyone help?

Kasper-Srensens-MacBook-Pro:~ Kasper$ git remote add origin ssh://[email protected]:2227/www/mechatronicscluster/wp-content.git fatal: Not a git repository (or any of the parent directories): .git Kasper-Srensens-MacBook-Pro:~ Kasper$

like image 987
caneclap Avatar asked Dec 21 '22 17:12

caneclap


1 Answers

You have to be in a git repository to add a remote for this specific repository. Use cd to change the current directory.

like image 91
Simon Avatar answered Jan 03 '23 05:01

Simon