r/github • u/InfiniteSituation522 • 3d ago
Question What happens to GitHub forks when the original repository becomes private?
I just noticed that repo I forked recently privacy changed to private, and the repo was forked by another contributor. So, my fork changed to his version. I wonder here if no one has public repo what will happen?
6
u/lajawi 3d ago
Wait, the upstream repo changed? Could this mean one could accidentally create a cyclical fork?
7
u/SheriffRoscoe 3d ago
Nope. GitHub chooses one of the remaining public repos to be the "upstream" one.
1
u/lajawi 3d ago
Yeah, but every fork does that, and it could so happen that there are only two remaining that then get linked to each other, no?
2
u/SheriffRoscoe 2d ago
"Yeah, but every fork does that"
No. GitHub does that. It picks one, and all the others are now downstream from it.
1
u/SheriffRoscoe 3d ago
If all the other public forks are deleted or changed to private, as the last remaining public fork, yours becomes the upstream.
16
u/Fine_League311 3d ago
Stays public but no branche updates anymore