NAME
git-prune - Prune all unreachable objects from the object databaseSYNOPSIS
git prune [-n] [-v] [--progress] [--expire <time>] [--] [<head>...]
DESCRIPTION
OPTIONS
-n, --dry-runDo not remove anything; just report what it
would remove.
-v, --verbose
Report all removed objects.
--progress
Show progress.
--expire <time>
Only expire loose objects older than
<time>.
--
Do not interpret any more arguments as
options.
<head>...
In addition to objects reachable from any of
our references, keep objects reachable from listed <head>s.
EXAMPLES
To prune objects not used by your repository or another that borrows from your repository via its .git/objects/info/alternates:$ git prune $(cd ../another && git rev-parse --all)
NOTES
In most cases, users will not need to call git prune directly, but should instead call git gc, which handles pruning along with many other housekeeping tasks.SEE ALSO
git-fsck(1), git-gc(1), git-reflog(1)GIT
Part of the git(1) suite02/28/2023 | Git 2.39.2 |