4 ms·
I want to use Dear ImGui [1] in a C++ project. Sure I can copy the relevant files into my repo by hand, but my instinct says that is not the way. Git submodule
by tigerlily 6y ago
I want to use Dear ImGui [1] in a C++ project. Sure I can copy the relevant files into my repo by hand, but my instinct says that is not the way. Git submodule seems like the right tool, but there's plenty of comments here advising not to use it. So if not git-submodule, then what is the procedure?
I just want to have the external repo as a subfolder in my own repo, updating that subfolder as updates become available.
[1] https://github.com/ocornut/imgui https://github.com/ocornut/imgui
- nerdponx 6y agoGit submodule is the right tool. Git submodule works well for externally-developed "read-only" parts of your project that you need to update infrequently. Git submodules a few years ago used to be a pain in the ass, partly because the CLI was missing a lot of important functionality. Pretty much all of those concerns are in the past, and now it's just people complaining about having to pass a couple extra command line flags (which you can/should just add to your README).
- tigerlily 6y agoThanks! A quick perusal of some reputable docs corroborates your recommendation [1]. [1] https://www.atlassian.com/git/tutorials/git-submodule https://www.atlassian.com/git/tutorials/git-submodule