유돌이

calendar

1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31

Notice

2019. 9. 25. 11:23 유닉스*리눅스*SE

원격 저장소 URL 변경하기

기존 원격 저장소 URL을 변경하기 위해 git remote set-url 명령어를 사용합니다:

$ git remote -v # View existing remotes origin https://github.com/user/repo.git (fetch) origin https://github.com/user/repo.git (push) $ git remote set-url origin https://github.com/user/repo2.git # Change the 'origin' remote's URL

$ git remote -v

# Verify new remote URL origin https://github.com/user/repo2.git (fetch) origin https://github.com/user/repo2.git (push)

두 개의 인자를 가집니다:

기존 원격 저장소 이름: origin

새로운 원격 저장소 URL : https://github.com/user/repo2.git

Troubleshooting 문제 해결


No such remote ‘[name]’

이 에러는 이름을 변경할 원격 저장소가 없음을 의미합니다.

관련 문서


Git remote man page

Pro Git - Working with Remotes

posted by 유돌이