Reputation: 1343
Hi I delete submodule which I didn't have access after some commits I found then I need that submodule back because other use it but currently it's private and I can't add using add submodule how to return deleted git submodule?
Upvotes: 0
Views: 304
Reputation: 968
how did you remove the submodules?
If you removed it via removing if from your .gitmodules
file or from .git/config
, then you just need to undo it. The data/code from the submodule will still be there locally.
However if you've removed from your disk and the project has been made private, then there's very little you can do. Perhaps there's a fork of the repo or one of your co-workers/friends has the copy of the submodule than you can reuse.
Upvotes: 2