I want to have total of 3 repositories:
ProjectA:
src
core
core.js
intro.js
outro.js
ProjectB:
src
core (shared from ProjectA)
core.js (shared from ProjectA)
feature1
feature1.js
intro.js (shared from ProjectA)
outro.js (shared from ProjectA)
ProjectC:
src
core (shared from ProjectA)
core.js (shared from ProjectA)
feature1 (shared from ProjectB)
feature1.js (shared from ProjectB)
intro.js (shared from ProjectA)
outro.js (shared from ProjectA)
all.js
The problematic part is that I want in ProjectB and ProjectC to have shared files in the same directory. What I mean by shared is they have the same history and when a user pushes to one of these files they are automatically updated in all other repositories and should share the same history.
I have read a lot of articles but never found what I was searching for. I believe it should be possible using server-side hooks and some kind of automatic push to the other repositories but I don't have any idea how to proceed with this.