Let’s say a repo named cool-stuff is on github.
I have a fork of cool-stuff and I have submitted a PR associated with my fork of cool-stuff which is waiting to be merged.

Now, there is another independent fork of cool-stuff,say, even-cooler-stuff which works on new features to introduce to cool-stuff. I would like to contribute to the even-cooler-stuff repo but github won’t let me since I already have a fork of cool-stuff.

Is there any way to do what I want like this or should I manually tell the author of even-cooler-stuff the changes I want to do?

You are viewing a single thread.
View all comments
37 points
*

You can add the even-cooler-stuff as another remote repo(like origin) and grab those changes and branch off of one of is branches then you can make pull requests to even cooler stuff from those branches.

https://stackoverflow.com/questions/7244321/how-do-i-update-or-sync-a-forked-repository-on-github

I’m pretty confident the reason GitHub isn’t allowing you to fork the even-cooler-stuff repo is that technically they are the same repo… And multiple remotes should do the trick.

permalink
report
reply
19 points
*

I blame GitHub for this. They invented this cool concept of a “fork” which is not technically a fork but only a stupid clone with another remote URL, and “pull request” which is basically a merge request with another name. It’s confusing and seem to create problems across teams /rant

permalink
report
parent
reply
10 points
*

The name “pull request” is actually more accurate, because you ask the upstream repository to git pull the changes from the downstream repo.

permalink
report
parent
reply
6 points

Either one works imo, as the maintainer is asked to merge your changes into his repo.

permalink
report
parent
reply
2 points

It’s only more accurate because they actually put the fork in a “different” repo (which really is the same repo).

If you only have one repo like in Gitlab, merge request is more accurate.

permalink
report
parent
reply
1 point

So, if I understand correctly,you mean :

  1. make a new repo and add even-cooler-stuff as remote.
  2. fetch changes from the remote even-cooler-stuff.
  3. make your changes and push to your repo

now I should be able to make a pull request?

permalink
report
parent
reply
4 points
*
  1. Use your existing fork of ‘cooler-stufff’

Everything else is the same.

Edit: you should actually be able to make a new repo and just file your three steps… Give it a try.

permalink
report
parent
reply
3 points

Apparently, someone else posted the same solution that I did while I typed it out. Sorry for the duplicate but at least weagree on the solution! A warning on this one though. You want to use a feature branch too. Otherwise you’ll mix your changes for cool-stuff with new changes for and from even-cooler-stuff. It may become more confusing and difficult to merge.

permalink
report
parent
reply

Programming

!programming@programming.dev

Create post

Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!

Cross posting is strongly encouraged in the instance. If you feel your post or another person’s post makes sense in another community cross post into it.

Hope you enjoy the instance!

Rules

Rules

  • Follow the programming.dev instance rules
  • Keep content related to programming in some way
  • If you’re posting long videos try to add in some form of tldr for those who don’t want to watch videos

Wormhole

Follow the wormhole through a path of communities !webdev@programming.dev



Community stats

  • 3.2K

    Monthly active users

  • 1.8K

    Posts

  • 30K

    Comments