티스토리 뷰
Github UIprivate-repo
를 통해 새로운 Repo를 생성하십시오 . 이후
git clone --bare https://github.com/exampleuser/public-repo.git
cd public-repo.git
git push --mirror https://github.com/yourname/private-repo.git
cd ..
rm -rf public-repo.git
명령어 입력
개인 repo를 복제하여 작업 할 수 있습니다.
git clone https://github.com/yourname/private-repo.git
cd private-repo
make some changes
git commit
git push origin master
public 에서 풀받기
cd private-repo
git remote add public https://github.com/exampleuser/public-repo.git
git pull public master # Creates a merge commit
git push origin master
Finally, to create a pull request private repo -> public repo:
The only way to create a pull request is to have push access to the public repo. This is because you need to push to a branch there (here's why).
git clone https://github.com/exampleuser/public-repo.git
cd public-repo
git remote add private_repo_yourname https://github.com/yourname/private-repo.git
git checkout -b pull_request_yourname
git pull private_repo_yourname master
git push origin pull_request_yourname