I'm cloning many third-party projects' git repo under a "Third-party Software" subdirectory in my workspace, however I don't want to keep any history from them(the latest snapshot will do); also I'm sharing many same submodules in many project in separate repositories(like clean filter, pre-commit scripts...etc.) and don't want to keep history in any of them.
Here's two similar but slightly different questions:
- Is there any command to make these git repositories to drop all history snapshots?
- Is there any git config (or other method) to force git repositories/submodules to only keep the latest snapshot after every future pull/submodule update?
Thank you.