0

I was able to successfully push my commits in my repository by my username and password. But I want to push those commits to someone who exactly forked my repository.I tried to follow this tutorial but It is on how to keep your repository sync with upstream repository. Can anyone help me with this?

Samuel Mideksa
  • 423
  • 8
  • 19

2 Answers2

1

You need to:

  1. Check out their repository
  2. Create a branch
  3. Replay the changes from your repository onto your branch in their repository
  4. Push your changes
  5. Create a pull request so they can merge your changes
CodeCaster
  • 147,647
  • 23
  • 218
  • 272
1

You could set his repository as a secondary remote upstream, like so:

git remote add <name> <url>

Give it any name you'd like, and the url of the forked repo (not the original one).

Then you can follow the same steps as the link you posted, replacing upstream with the upstream name you set up above.

  • In which step? If on step 4, you can: a. create another branch from the fork's master branch, e.g. `git checkout fork_upstream/master -b fork/master`, or b. reset the upstream from your local master to point to fork_upstream/master instead. If you have checked out master from origin before, it will still be pointing to it. You would need a local branch pointing to the forked master. – Leonardo Camara Sep 06 '18 at 13:03