반응형
깃허브에서 다른 사람의 포크에 가지를 가져오려면 어떻게 해야 합니까?
GitHub의 평판에서 포크를 가져왔습니다.저는 다른 사용자의 포크에 있는 지점에서 코드를 얻고 싶습니다.
이 사용자의 전체 보고서를 별도의 로컬 보고서로 복제해야 합니까? 아니면 다음과 같은 작업을 수행할 수 있습니까?git checkout link_to_the_other_users_branch
?
$ git remote add theirusername git@github.com:theirusername/reponame.git
$ git fetch theirusername
$ git checkout -b mynamefortheirbranch theirusername/theirbranch
첫 번째 단계에서 원격을 추가할 때 사용할 수 있는 "올바른" URI가 여러 개 있습니다.
git@github.com:theirusername/reponame.git
SSH 기반 URI입니다.https://github.com/theirusername/reponame.git
HTTPS URI입니다.
어떤 것을 사용하고 싶은지는 상황에 따라 달라집니다.GitHub에는 차이점을 설명하고 다음을 선택하는 데 도움이 되는 도움말 기사가 있습니다.원격 리포지토리의 URL 선택
합금의 제안은 저에게 효과가 없었습니다.이 작업은 다음과 같습니다.
git remote add theirusername https://github.com/theirusername/reponame
git fetch theirusername
git checkout -b mynamefortheirbranch theirusername/theirbranch
리소스:
- https://git-scm.com/book/ch2-5.html
- http://crunchify.com/how-to-fork-github-repository-create-pull-request-and-merge/
언급URL : https://stackoverflow.com/questions/9153598/how-do-i-fetch-a-branch-on-someone-elses-fork-on-github
반응형
'programing' 카테고리의 다른 글
Firebase Cloud Firestore: 수집 참조가 잘못되었습니다.컬렉션 참조에는 홀수의 세그먼트가 있어야 합니다. (0) | 2023.06.27 |
---|---|
Chrome이 변경 시 Typescript 원본 파일을 업데이트하지 않는 이유는 무엇입니까? (0) | 2023.06.27 |
WordPress 플러그인에서 프로그래밍 방식으로 Mod Rewrite 규칙 추가 (0) | 2023.06.27 |
멀리 떨어진 지점에서 체리를 따는 방법? (0) | 2023.06.27 |
파이썬에서 외부 명령을 비동기식으로 실행하려면 어떻게 해야 합니까? (0) | 2023.06.27 |