There's one possibility I've never tried "for real" but that might work well.
Let's say you have three projects creatively named Proj1, Proj2 and (guess it) Proj3. Let's also say that all or some of them depend on external libraries, for example one called Lib1.dll and another called SuperLib.dll.
First, for the folder structure, I'd do something like:
MyCode\
build_all.bat
Docs\
[...]
Libs\
Lib1.dll
SuperLib.dll
Proj1\
[...]
Proj2\
[...]
Proj3\
[...]
Then you would create one repository on each of the ProjX folders:
cd \MyCode\Proj1
git init
cd \MyCode\Proj2
git init
cd \MyCode\Proj3
git init
Then you would create a repository for the whole thing:
cd \MyCode
git init
The contents of this repository, for git, would be the Libs
folder and its contents, the build_all.bat
build script, and 3 subprojects.
So once you change your source code, let's say Proj1\Main.cs
, the whole thing wouldn't see the modification. You would have to git commit
on Proj1, and then you would go to the whole thing and then git commit
it (now git will be able to see that Proj1 has been modified).
Using this method, the history of the whole thing would simply state when the ProjX were modified, but it would not directly keep track of individual files. Howver, as expected, the repository on ProjX would keep track of every file, as usual.
If you give it a try on a "real project", let me know the results!
Good luck!