git change upstream code example

Example 1: change remote repository git

git remote set-url origin git@accountname.git.beanstalkapp.com:/your-repository.git

Example 2: change remote url git

git remote set-url origin https://hostname/USERNAME/REPOSITORY.git

Example 3: set git origin

git remote add origin git@git.assembla.com:portfolio/space.space_name.git

Example 4: git bash upstream branch change

git branch --set-upstream-to=origin/branch

Example 5: how to change git remote origin

git remote set-url origin new.git.url/here

Example 6: git bash upstream branch change

git config --edit