Re: [PATCH 5/6] git-reflog: add create and exists functions

2015-06-25 Thread David Turner
On Thu, 2015-06-25 at 11:35 -0700, Junio C Hamano wrote: Junio C Hamano gits...@pobox.com writes: Now, going back to 4/6, I think create_reflog() function as an external API has a few problems. * Its name does not tell us what should happen when a reflog already exists for the

Re: [PATCH 5/6] git-reflog: add create and exists functions

2015-06-25 Thread Junio C Hamano
David Turner dtur...@twopensource.com writes: These are necessary because ref backends manage reflogs. Because? Because with core.logAllRefUpdates set to false, creating or updating a ref would not log what is done to it, unless a reflog already exists for the ref.

Re: [PATCH 5/6] git-reflog: add create and exists functions

2015-06-25 Thread Junio C Hamano
Junio C Hamano gits...@pobox.com writes: Now, going back to 4/6, I think create_reflog() function as an external API has a few problems. * Its name does not tell us what should happen when a reflog already exists for the refname the caller asked to create reflog for. I understand

[PATCH 5/6] git-reflog: add create and exists functions

2015-06-24 Thread David Turner
These are necessary because ref backends manage reflogs. In a moment, we will use these functions to make git stash work with alternate ref backends. Signed-off-by: David Turner dtur...@twopensource.com --- builtin/reflog.c | 81 +++- 1 file