Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Pull requests across separate GitHub repositories that weren't forked from one another?

Tags:

git

github

Is it possible to make pull requests between two different Github repositories? For example, if I have a branch called new-feature in Repository A, can I create a pull request and merge the changes into the master branch in Repository B?

Merging across repos is possible in git, but I can't find anything suggesting that Github supports it.

like image 443
Katrina Avatar asked Jan 08 '16 15:01

Katrina


People also ask

Is it possible to make pull requests between two different GitHub repositories?

Is it possible to make pull requests between two different Github repositories? For example, if I have a branch called new-featurein Repository A, can I create a pull request and merge the changes into the masterbranch in Repository B? Merging across repos is possible in git, but I can't find anything suggesting that Github supports it.

Can I merge changes across Repos in Git?

For example, if I have a branch called new-featurein Repository A, can I create a pull request and merge the changes into the masterbranch in Repository B? Merging across repos is possible in git, but I can't find anything suggesting that Github supports it.

Who can approve pull requests in a public repository?

By default, in public repositories, any user can submit reviews that approve or request changes to a pull request. Organization owners and repository admins can limit who is able to give approving pull request reviews or request changes.

How do I Fork a project on GitHub?

Click "Fork" on the upstream project's GitHub page. After the forking process is complete, clone that repository to your local computer (I'll call this "the forked repo"). Copy all changed files from the copied repo into the forked repo. Verify that it's working as you expect, then look at the changes using git status and git diff and commit them.


1 Answers

The following would merge the changes of ProjectA with the ProjectB

# go to  projectB:
git remote add projectA path/to/projectA/NewFeature
git fetch projectA
git merge projectA/master 

Now Push these changes to your github ProjectB repository.

git push origin master
like image 140
SloppyJoe Avatar answered Sep 20 '22 01:09

SloppyJoe