bash completion: remove deprecated --prune from git-gc
PATCH 1/1 bash completion: remove deprecated --prune from git-gc
--- contrib/completion/git-completion.bash | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
contrib/completion/git-completion.bash +1 -1
@@ -835,7 +835,7 @@ _git_gc () local cur="${COMP_WORDS[COMP_CWORD]}" case "$cur" in --*) - __gitcomp "--prune --aggressive" + __gitcomp "--aggressive" return ;; esac
Signature · 1 line
1.6.1.rc1.54.gd1643
Hi,
contrib/completion/git-completion.bash _git_gc () · line 838
Quoted 2 lines · Markus Heidelberg
contrib/completion/git-completion.bash +1
-1- __gitcomp "--prune --aggressive" + __gitcomp "--aggressive"
git gc --prune is deprecated? That's news to me.
How would you suggest, then, to remove the loose objects you always get with conflicts in a merge?
Ciao,
Dscho
Quoted 3 lines · Johannes Schindelin
contrib/completion/git-completion.bash _git_gc () · line 838
Quoted 2 lines
contrib/completion/git-completion.bash +1
-1- __gitcomp "--prune --aggressive" + __gitcomp "--aggressive"git gc --prune is deprecated? That's news to me.
Check out 9e7d501 (builtin-gc.c: deprecate --prune, it now really has no effect, 2008-05-09).
Which annoyingly has no discussion about _why_ it no longer has an effect. But I suspect it has something to do with 25ee973 (gc: call "prune --expire 2.weeks.ago" by default, 2008-03-12) by you.
-Peff
Quoted 6 lines · Jeff King
Quoted 3 lines · Johannes Schindelin
contrib/completion/git-completion.bash _git_gc () · line 838
Quoted 2 lines
contrib/completion/git-completion.bash +1
-1- __gitcomp "--prune --aggressive" + __gitcomp "--aggressive"git gc --prune is deprecated? That's news to me.
Quoted 6 lines
Check out 9e7d501 (
builtin-gc.c: deprecate --prune, it now really has no effect, 2008-05-09).Which annoyingly has no discussion about _why_ it no longer has an effect. But I suspect it has something to do with 25ee973 (gc: call "prune --expire 2.weeks.ago" by default, 2008-03-12) by you.
I think the nail in the coffin for --prune was a37cce3b, which preceded 9e7d501. I guess the commit message for 9e7d501 made sense with a37cce3b as a reference. There was another commit around the same time which claimed that --prune was deprecated even though it still provided some functionality, hence the "...really has no effect" part.
I definitely remember that Johannes implemented the gc.pruneExpire functionality, so his "That's news to me" made me laugh. Thanks for the chuckle Johannes. :)
-brandon
Hi,
Quoted 6 lines · Jeff King
Quoted 3 lines · Johannes Schindelin
contrib/completion/git-completion.bash _git_gc () · line 838
Quoted 2 lines
contrib/completion/git-completion.bash +1
-1- __gitcomp "--prune --aggressive" + __gitcomp "--aggressive"git gc --prune is deprecated? That's news to me.
Quoted 6 lines
Check out 9e7d501 (
builtin-gc.c: deprecate --prune, it now really has no effect, 2008-05-09).Which annoyingly has no discussion about _why_ it no longer has an effect. But I suspect it has something to do with 25ee973 (gc: call "prune --expire 2.weeks.ago" by default, 2008-03-12) by you.
Oops.
But I thought that git gc --prune does expire _all_ dangling loose objects _now_, not with --expire 2.weeks.ago.
Ciao,
Dscho
Quoted 8 lines · Johannes Schindelin
Quoted 3 lines
Which annoyingly has no discussion about _why_ it no longer has an effect. But I suspect it has something to do with 25ee973 (gc: call "prune --expire 2.weeks.ago" by default, 2008-03-12) by you.
Oops.
But I thought that git gc --prune does expire _all_ dangling loose objects _now_, not with --expire 2.weeks.ago.
Nope, see 25ee973. You explicitly wrote:
Note that this new behaviour makes "--prune" be a no-op.
That being said, I think that is perhaps a reasonable thing for --prune to do (and I don't think there is any conflict with the name, because that is what it _used_ to do before becoming a no-op). But nobody has actually implemented it.
-Peff
Quoted 10 lines · Jeff King
Quoted 7 lines · Johannes Schindelin
Quoted 3 lines
Which annoyingly has no discussion about _why_ it no longer has an effect. But I suspect it has something to do with 25ee973 (gc: call "prune --expire 2.weeks.ago" by default, 2008-03-12) by you.
Oops.
But I thought that git gc --prune does expire _all_ dangling loose objects _now_, not with --expire 2.weeks.ago.
Quoted 8 lines
Nope, see 25ee973. You explicitly wrote:
Note that this new behaviour makes "--prune" be a no-op.
That being said, I think that is perhaps a reasonable thing for --prune to do (and I don't think there is any conflict with the name, because that is what it _used_ to do before becoming a no-op). But nobody has actually implemented it.
Maybe --mrproper would be a more appropriate name.
-brandon
Quoted 6 lines · Johannes Schindelin
contrib/completion/git-completion.bash _git_gc () · line 838
Quoted 2 lines · Markus Heidelberg
contrib/completion/git-completion.bash +1
-1- __gitcomp "--prune --aggressive" + __gitcomp "--aggressive"git gc --prune is deprecated? That's news to me.
More like "git gc --prune" is no-op now.
Quoted 2 lines
How would you suggest, then, to remove the loose objects you always get with conflicts in a merge?
"git gc" does pruning of loose objects, but protected by grace period for loose objects with gc.pruneexpire
You always have (admittedly lowe level) git-prune.
Signature · 3 lines
Jakub Narebski Poland ShadeHawk on #git