I know there are sub trees and sub modules within GIT but i am still not sure which one would be the best option in my case.
So the situation is this:
- I have a project with "lib1" and "lib2", project and repo are already there, i am not starting from scratch
- I want to keep all the project in the same GIT repo for easier checkin/checkout and since i mainly work on that repo
- Project is not open source but i would like to open source "lib2"
- I will never work on "lib2" alone, only within the main project
- I am not expecting contributions to lib2 so merging from its repo its a minor issue
- Ideally i'd like this to be transparent to other devs working on this project (so when they commit/push they won't need to know that there is a subtree below)
So, the idea would be to be able to push "lib2" with its own history keeping all the rest of the project private. I know there are a lot of questions on this topic already but i wasnt able to find a clear answer.