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

前端 未结 8 1048
小鲜肉
小鲜肉 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:55

    Taken from Git push everything to new origin

    basically you have to associate a new repo to your folder

    git remote add origin <address>
    git push origin <branchname>
    
    0 讨论(0)
  • 2021-01-29 17:59

    Delete git and re-init.

    Your purpose is probably to put this repo on yours and make it yours.

    The idea is to delete the .git/ and re-initialize.

    1. go to your cloned repo folder rm -rf .git
    2. re-initialize it and then add your remote and do your first push.
      git init
      git add .
      git commit -m "your commit message"
      git remote add origin 
      git push origin master
      
    0 讨论(0)
提交回复
热议问题