Cloning a repo from someone else's Github and pushing it to a repo on my Github

前端 未结 8 1205
小鲜肉
小鲜肉 2021-01-29 17:18

I cloned the repo at https://github.com/railstutorial/sample_app_rails_4 and made a lot of changes to it (I used it as a starting point for my own app), and now I would like to

8条回答
  •  无人共我
    2021-01-29 17:47

    I think that the "most polite way" to do so would be:

    1. Fork the original repo on your GitHub account
    2. Checkout a new branch for your changes git checkout -b (in case you didn't do that before)
    3. Add a new remote for your local repository: git remote add github
    4. Push your beautiful new branch to your github repository: git push github

    In this way you will have a repo forked to the original one, with your changes commited in a separate branch. This way will be easier in case you want to submit a pull request to the original repo.

提交回复
热议问题