-1

I'm attempting to finish an Azure web app tutorial. In the step "Push to Azure from Git", I'm attempting to push to Github using, but getting error message

SivesA@ONE7-FAL138552 MINGW64 /c/2017/11 November/20112017/nodejs-docs-hello-world-master (master)
$ git remote add azure https://nodejsuser2@nodejswebappadamsives2.scm.azurewebsites.net/nodejswebappadamsives2.git
fatal: remote azure already exists.

no matter what URL I use.

I've been sure to inititalise and commit the project. I've also tried resolution through another SO question, but seem to be hitting a brick wall. My remote properties are as follows:

SivesA@ONE7-FAL138552 MINGW64 /c/2017/11 November/20112017/nodejs-docs-hello-world-master (master)
$ git remote -v show
azure   https://adamsives@nodejswebapp.scm.azurewebsites.net/nodejswebapp.git (fetch)
azure   https://adamsives@nodejswebapp.scm.azurewebsites.net/nodejswebapp.git (push)

the Github repository is https://nodejsuser2@nodejswebappadamsives2.scm.azurewebsites.net/nodejswebappadamsives2.git

Nimbocrux
  • 509
  • 2
  • 10
  • 27
  • The error message is extremely straightforward. The remote already exists. Why are you trying to create it again? – jpmc26 Nov 20 '17 at 05:47

1 Answers1

2

It seems that the remote with the name azure already exists on your system and that remote contains the url "https://adamsives@nodejswebapp.scm.azurewebsites.net/nodejswebapp.git".

As you have mentioned that you want your remote url as "https://nodejsuser2@nodejswebappadamsives2.scm.azurewebsites.net/nodejswebappadamsives2.git". Therefore your need to do the following steps to update the url of the remote "azure":-

git remote set-url azure https://nodejsuser2@nodejswebappadamsives2.scm.azurewebsites.net/nodejswebappadamsives2.git

OR

You can add a new remote with new name like "newazure" with it's URL as you want. Follow the below command to add new:-

git remote add newazure https://nodejsuser2@nodejswebappadamsives2.scm.azurewebsites.net/nodejswebappadamsives2.git
Ronit Mukherjee
  • 405
  • 2
  • 10