Re: [PATCH] diff: add tests for --relative without optional prefix value

2017-12-07 Thread Jacob Keller
On Thu, Dec 7, 2017 at 1:50 PM, Junio C Hamano wrote: > Jeff King writes: > >> On Thu, Dec 07, 2017 at 11:01:35AM -0800, Jacob Keller wrote: >> >>> From: Jacob Keller >>> >>> We already have tests for --relative, but they currently only

Re: [PATCH v2 5/7] diff: use skip-to-optional-val in parsing --relative

2017-12-07 Thread Jeff King
On Thu, Dec 07, 2017 at 01:59:39PM -0800, Junio C Hamano wrote: > Jeff King writes: > > > On Thu, Dec 07, 2017 at 09:30:32AM -0800, Junio C Hamano wrote: > > > >> Signed-off-by: Junio C Hamano > >> --- > > > > It might be worth mentioning why this conversion

[PATCH] decorate: clean up and document API

2017-12-07 Thread Jonathan Tan
Improve the names of the identifiers in decorate.h, document them, and add an example of how to use these functions. The example is compiled and run as part of the test suite. Signed-off-by: Jonathan Tan --- This patch contains some example code in a test helper.

Re: [PATCH] fmt-merge-msg: avoid leaking strbuf in shortlog()

2017-12-07 Thread Junio C Hamano
René Scharfe writes: > Use string_list_append_nodup() instead of string_list_append() to hand > over ownership of a detached strbuf and thus avoid leaking its memory. > > Signed-off-by: Rene Scharfe > --- > builtin/fmt-merge-msg.c | 3 ++- > 1 file changed, 2

[PATCH 0/1] diffcore-blobfind

2017-12-07 Thread Stefan Beller
This includes the suggestions by Junio, Thanks, Stefan interdiff to currently queued below. Stefan Beller (1): diffcore: add a filter to find a specific blob Documentation/diff-options.txt | 5 + Makefile | 1 + builtin/log.c | 2 +- diff.c

[PATCH 1/1] diffcore: add a filter to find a specific blob

2017-12-07 Thread Stefan Beller
Sometimes users are given a hash of an object and they want to identify it further (ex.: Use verify-pack to find the largest blobs, but what are these? or [1]) One might be tempted to extend git-describe to also work with blobs, such that `git describe ` gives a description as ':'. This was

Re: [PATCH v2 5/7] diff: use skip-to-optional-val in parsing --relative

2017-12-07 Thread Junio C Hamano
Jeff King writes: > On Thu, Dec 07, 2017 at 09:30:32AM -0800, Junio C Hamano wrote: > >> Signed-off-by: Junio C Hamano >> --- > > It might be worth mentioning why this conversion is pulled out from the > others (because its "default" case is "do not touch the

Re: [PATCH v2 5/7] diff: use skip-to-optional-val in parsing --relative

2017-12-07 Thread Junio C Hamano
Jeff King writes: > On Thu, Dec 07, 2017 at 01:59:39PM -0800, Junio C Hamano wrote: > >> Jeff King writes: >> >> > On Thu, Dec 07, 2017 at 09:30:32AM -0800, Junio C Hamano wrote: >> > >> >> Signed-off-by: Junio C Hamano >> >> --- >> > >> > It

Re: [WIP 03/15] pkt-line: add delim packet support

2017-12-07 Thread Stefan Beller
On Mon, Dec 4, 2017 at 3:58 PM, Brandon Williams wrote: > One of the design goals of protocol-v2 is to improve the semantics of > flush packets. Currently in protocol-v1, flush packets are used both to > indicate a break in a list of packet lines as well as an indication that

Re: [PATCH v5 4/4] builtin/branch: strip refs/heads/ using skip_prefix

2017-12-07 Thread Junio C Hamano
Junio C Hamano writes: > SZEDER Gábor writes: > >> On Fri, Dec 1, 2017 at 6:59 AM, Kaartic Sivaraam >> wrote: >>> Sorry, missed a ';' in v4. >>> >>> The surprising thing I discovered in the TravisCI build for v4 >>> was that

Re: [PATCH] diff: add tests for --relative without optional prefix value

2017-12-07 Thread Junio C Hamano
Jeff King writes: > On Thu, Dec 07, 2017 at 11:01:35AM -0800, Jacob Keller wrote: > >> From: Jacob Keller >> >> We already have tests for --relative, but they currently only test when >> a prefix has been provided. This fails to test the case where

Re: [PATCH] hashmap: adjust documentation to reflect reality

2017-12-07 Thread Johannes Schindelin
Hi, On Mon, 4 Dec 2017, Stefan Beller wrote: > On Sat, Dec 2, 2017 at 9:35 PM, Junio C Hamano wrote: > > Jeff King writes: > > > >> My second suggestion (which I'm on the fence about) is: would it better > >> to just say "see t/helper/test-hashmap.c for a

Re: [PATCH v5 4/4] builtin/branch: strip refs/heads/ using skip_prefix

2017-12-07 Thread Junio C Hamano
SZEDER Gábor writes: > On Fri, Dec 1, 2017 at 6:59 AM, Kaartic Sivaraam > wrote: >> Sorry, missed a ';' in v4. >> >> The surprising thing I discovered in the TravisCI build for v4 >> was that apart from the 'Documentation' build the 'Static

Re: [PATCH 1/1] diffcore: add a filter to find a specific blob

2017-12-07 Thread Junio C Hamano
Junio C Hamano writes: After saying "Will merge to 'next'" in the recent "What's cooking" report, I noticed that a few loose ends were never tied on this topic. >> diff --git a/Documentation/diff-options.txt b/Documentation/diff-options.txt >> index dd0dba5b1d..252a21cc19

Re: [WIP 11/15] serve: introduce git-serve

2017-12-07 Thread Junio C Hamano
Brandon Williams writes: > +static struct protocol_capability *get_capability(const char *key) > +{ > + int i; > + > + if (!key) > + return NULL; > + > + for (i = 0; i < ARRAY_SIZE(capabilities); i++) { > + struct protocol_capability *c =

Re: [SCRIPT/RFC 0/3] git-commit --onto-parent (three-way merge, no working tree file changes)

2017-12-07 Thread Igor Djordjevic
On 06/12/2017 19:34, Johannes Sixt wrote: > > I am sorry for not responding in detail. I think we've reached a > mutual understanding of our workflows. No problem, thanks for your time so far. There might be one more thing I should address, possibly left unclear from my previous message, but

Re: What's cooking in git.git (Dec 2017, #01; Mon, 4)

2017-12-07 Thread Todd Zullinger
Jeff Hostetler wrote: I'm looking at t5616 now on my mac. Looks like the MAC doesn't like my line counting in the tests. I'll fix in my next version. Perhaps that's as simple as using the test_line_counts helper? diff --git i/t/t5616-partial-clone.sh w/t/t5616-partial-clone.sh index

Re: [WIP 02/15] pkt-line: introduce struct packet_reader

2017-12-07 Thread Stefan Beller
On Mon, Dec 4, 2017 at 3:58 PM, Brandon Williams wrote: > Sometimes it is advantageous to be able to peek the next packet line > without consuming it (e.g. to be able to determine the protocol version > a server is speaking). In order to do that introduce 'struct >

[PATCH] docs/pretty-formats: mention commas in %(trailers) syntax

2017-12-07 Thread Jeff King
Commit 84ff053d47 (pretty.c: delimit "%(trailers)" arguments with ",", 2017-10-01) switched the syntax of the trailers placeholder, but forgot to update the documentation in pretty-formats.txt. There's need to mention the old syntax; it was never in a released version of Git. Signed-off-by: Jeff

Re: What's cooking in git.git (Dec 2017, #02; Thu, 7)

2017-12-07 Thread Torsten Bögershausen
> * tb/check-crlf-for-safe-crlf (2017-11-27) 1 commit > (merged to 'next' on 2017-12-05 at 7adaa1fe01) > + convert: tighten the safe autocrlf handling > > The "safe crlf" check incorrectly triggered for contents that does > not use CRLF as line endings, which has been corrected. > > Broken

Re: What's cooking in git.git (Dec 2017, #01; Mon, 4)

2017-12-07 Thread Junio C Hamano
Todd Zullinger writes: > Johannes Schindelin wrote: >> That is not the only thing going wrong: >> >> https://travis-ci.org/git/git/builds/312551566 >> >> It would seem that t9001 is broken on Linux32, t5616 is broken on macOS, >> and something really kinky is going on with

[PATCH] strbuf: release memory on read error in strbuf_read_once()

2017-12-07 Thread René Scharfe
If other strbuf add functions cause the first allocation and subsequently encounter an error then they release the memory, restoring the pristine state of the strbuf. That simplifies error handling for callers. Do the same in strbuf_read_once(), and do it also in case no bytes were read -- which

Re: [WIP 01/15] pkt-line: introduce packet_read_with_status

2017-12-07 Thread Stefan Beller
On Mon, Dec 4, 2017 at 3:58 PM, Brandon Williams wrote: > diff --git a/pkt-line.h b/pkt-line.h > index 3dad583e2..f1545929b 100644 > --- a/pkt-line.h > +++ b/pkt-line.h > @@ -60,8 +60,16 @@ int write_packetized_from_buf(const char *src_in, size_t > len, int fd_out); > * If

Re: What's cooking in git.git (Dec 2017, #01; Mon, 4)

2017-12-07 Thread Jeff Hostetler
On 12/7/2017 10:48 AM, Johannes Schindelin wrote: Hi, [...] That is not the only thing going wrong: https://travis-ci.org/git/git/builds/312551566 It would seem that t9001 is broken on Linux32, t5616 is broken on macOS, and something really kinky is going on with the

Re: What's cooking in git.git (Dec 2017, #01; Mon, 4)

2017-12-07 Thread Lars Schneider
> On 07 Dec 2017, at 21:50, Junio C Hamano wrote: > > Todd Zullinger writes: > >> Johannes Schindelin wrote: >>> That is not the only thing going wrong: >>> >>> https://travis-ci.org/git/git/builds/312551566 >>> >>> It would seem that t9001 is broken

Re: [PATCH v2 5/7] diff: use skip-to-optional-val in parsing --relative

2017-12-07 Thread Jeff King
On Thu, Dec 07, 2017 at 09:30:32AM -0800, Junio C Hamano wrote: > Signed-off-by: Junio C Hamano > --- It might be worth mentioning why this conversion is pulled out from the others (because its "default" case is "do not touch the pointer"). Other than that, it looks good to

Re: What's cooking in git.git (Dec 2017, #01; Mon, 4)

2017-12-07 Thread Junio C Hamano
Jeff Hostetler writes: > I'm looking at t5616 now on my mac. > Looks like the MAC doesn't like my line counting in the tests. Ah, of course, test "$(wc -l)" = number would not work over there we have "test_line_count" helper exactly for that purose.

Re: [PATCH] diff: add tests for --relative without optional prefix value

2017-12-07 Thread Jeff King
On Thu, Dec 07, 2017 at 11:01:35AM -0800, Jacob Keller wrote: > From: Jacob Keller > > We already have tests for --relative, but they currently only test when > a prefix has been provided. This fails to test the case where --relative > by itself should use the current

[PATCH] worktree: invoke post-checkout hook (unless --no-checkout)

2017-12-07 Thread Eric Sunshine
git-clone and git-checkout both invoke the post-checkout hook following a successful checkout, yet git-worktree neglects to do so even though it too "checks out" the worktree. Fix this oversight. Implementation note: The newly-created worktree may reference a branch or be detached. In the latter

Re: [PATCH] diff: add tests for --relative without optional prefix value

2017-12-07 Thread Jacob Keller
On Thu, Dec 7, 2017 at 1:12 PM, Jeff King wrote: > On Thu, Dec 07, 2017 at 11:01:35AM -0800, Jacob Keller wrote: > >> From: Jacob Keller >> >> We already have tests for --relative, but they currently only test when >> a prefix has been provided. This fails

Re: [PATCH] am: release strbuf after use in split_mail_mbox()

2017-12-07 Thread Jeff King
On Thu, Dec 07, 2017 at 09:20:19PM +0100, René Scharfe wrote: > Signed-off-by: Rene Scharfe > --- > builtin/am.c | 10 +++--- > 1 file changed, 7 insertions(+), 3 deletions(-) > > diff --git a/builtin/am.c b/builtin/am.c > index 02853b3e05..1ac044da2e 100644 > ---

Re: What's cooking in git.git (Dec 2017, #01; Mon, 4)

2017-12-07 Thread Junio C Hamano
Lars Schneider writes: >> The acl stuff hasn't changed for a long time and I do not think of a >> reason offhand why the test should behave differently between say >> 'maint' and 'pu', yet 'maint' is passing while 'pu' is not... > > My recent 657343a602 (travis-ci: move

Re: [PATCH] fmt-merge-msg: avoid leaking strbuf in shortlog()

2017-12-07 Thread Jeff King
On Thu, Dec 07, 2017 at 09:22:49PM +0100, René Scharfe wrote: > Use string_list_append_nodup() instead of string_list_append() to hand > over ownership of a detached strbuf and thus avoid leaking its memory. Looks obviously correct (though one thing missing from the diff context is whether

Re: [PATCH] strbuf: release memory on read error in strbuf_read_once()

2017-12-07 Thread Jeff King
On Thu, Dec 07, 2017 at 09:51:26PM +0100, René Scharfe wrote: > If other strbuf add functions cause the first allocation and > subsequently encounter an error then they release the memory, restoring > the pristine state of the strbuf. That simplifies error handling for > callers. > > Do the

Re: git commit file completion recently broke

2017-12-07 Thread Christian Couder
On Thu, Dec 7, 2017 at 1:56 AM, Jeff King wrote: > I think we'd do better to just assign NULL when there's "=", so we can > tell the difference between "--relative", "--relative=", and > "--relative=foo" (all of which are distinct). > > I think that's possible with the current

Unfortunate interaction between git diff-index and fakeroot

2017-12-07 Thread Elazar Leibovich
Hi, We noticed some unexpected behavior of git, when running git commands under fakeroot, and then running another command without fakeroot. When running, e.g., git status, or git describe --dirty, git can update the index file. This can happen inadvertently by, e.g., running the make install

Re: git commit file completion recently broke

2017-12-07 Thread Jeff King
On Thu, Dec 07, 2017 at 09:14:31AM +0100, Christian Couder wrote: > > I do think it may make sense for > > the "short" one to use NULL, like: > > > > skip_to_optional_val(arg, "--relative, ) > > > > but maybe some other callers would be more inconvenienced (they may have > > to current NULL

[PATCH] setup.c: fix comment about order of .git directory discovery

2017-12-07 Thread SZEDER Gábor
Since gitfiles were introduced in b44ebb19e (Add platform-independent .git "symlink", 2008-02-20) the order of checks during .git directory discovery is: gitfile, gitdir, bare repo. However, that commit did only partially update the in-code comment describing this order, missing the last line

Re: [PATCH v4] send-email: extract email-parsing code into a subroutine

2017-12-07 Thread Matthieu Moy
Not terribly important, but your patch has trailing newlines. "git diff --staged --check" to see them. More below. PAYRE NATHAN p1508475 writes: > the part of code which parses the header a last time to prepare the > email and send it. The important point is not

Re: git commit file completion recently broke

2017-12-07 Thread Junio C Hamano
Christian Couder writes: >> I do think it may make sense for >> the "short" one to use NULL, like: >> >> skip_to_optional_val(arg, "--relative, ) >> >> but maybe some other callers would be more inconvenienced (they may have >> to current NULL back into the empty

Re: partial_clone_get_default_filter_spec has no callers

2017-12-07 Thread Jeff Hostetler
On 12/6/2017 8:59 PM, Ramsay Jones wrote: On 06/12/17 21:07, Jeff Hostetler wrote: On 12/6/2017 12:39 PM, Ramsay Jones wrote: Hi Jeff, commit f1862e8153 ("partial-clone: define partial clone settings in config", 2017-12-05), which is part of your 'jh/partial-clone' branch, introduces

Re: [PATCH v5 2/2] launch_editor(): indicate that Git waits for user input

2017-12-07 Thread Junio C Hamano
lars.schnei...@autodesk.com writes: > + if (print_waiting_for_editor) { > + fprintf(stderr, > + _("hint: Waiting for your editor to close the > file... ")); > + if (is_terminal_dumb()) > +

Re: [PATCH] doc: clarify triangular workflow

2017-12-07 Thread Junio C Hamano
Matthieu Moy writes: > Not a native speaker, but according to wikipedia > (https://en.wikipedia.org/wiki/Singular_they) it's OK to write > "maintainer [singular, but already neulral] may get merge conflicts when > they [sinugular they] ..." Yes.

Re: Unfortunate interaction between git diff-index and fakeroot

2017-12-07 Thread Junio C Hamano
Elazar Leibovich writes: > We noticed some unexpected behavior of git, when running git commands under > fakeroot, and then running another command without fakeroot. > > When running, e.g., git status, or git describe --dirty, git can > update the index file.

[PATCH v5 0/2] launch_editor(): indicate that Git waits for user input

2017-12-07 Thread lars . schneider
From: Lars Schneider Hi, Patch 1/2: No change. The patch got "looks good to me" from Peff [1] Patch 2/2: I changed the waiting message to our bikeshedding result [2] and I enabled the waiting message on dumb terminals for consistency. I also tested the

[PATCH v5 1/2] refactor "dumb" terminal determination

2017-12-07 Thread lars . schneider
From: Lars Schneider Move the code to detect "dumb" terminals into a single location. This avoids duplicating the terminal detection code yet again in a subsequent commit. Signed-off-by: Lars Schneider --- cache.h| 1 + color.c| 3

[PATCH v5 2/2] launch_editor(): indicate that Git waits for user input

2017-12-07 Thread lars . schneider
From: Lars Schneider When a graphical GIT_EDITOR is spawned by a Git command that opens and waits for user input (e.g. "git rebase -i"), then the editor window might be obscured by other windows. The user might be left staring at the original Git terminal window without

Re: [PATCH v2] diff: fix --relative without arguments

2017-12-07 Thread Junio C Hamano
Jacob Keller writes: > From: Jacob Keller > > Recently, commit f7923a5ece00 ("diff: use skip_to_optional_val()", > 2017-12-04) changed how we parsed some diff options, preferring > skip_to_optional_val instead of a more complex skip_prefix()

Re: 'git worktree add' does not fire post-checkout hook

2017-12-07 Thread Eric Sunshine
On Wed, Dec 6, 2017 at 4:45 PM, Eric Sunshine wrote: > On Wed, Dec 6, 2017 at 4:00 PM, Gumbel, Matthew K > wrote: >> I've noticed that when I run 'git worktree add /path/to/new/tree', >> the post-checkout hook does not fire, even though the

[PATCH v4] send-email: extract email-parsing code into a subroutine

2017-12-07 Thread Nathan Payre
The existing code mixes parsing of email header with regular expression and actual code. Extract the parsing code into a new subroutine "parse_header_line()". This improves the code readability and make parse_header_line reusable in other place. "parsed_header_line()" and "filter_body()" could be

re

2017-12-07 Thread Eiman Yousef Al-muzafar
Assalam Alaikum, I am Eiman Yousef M A Al-muzafar, a Muslim woman from Qatar, I am contacting you regarding a relationship of trust and confidence for an inheritance. Please contact me on my private email for more details: ey_muza...@hotmail.com

Re: partial_clone_get_default_filter_spec has no callers

2017-12-07 Thread Luc Van Oostenryck
On Thu, Dec 07, 2017 at 01:59:26AM +, Ramsay Jones wrote: > > BTW, if you are using a version of sparse post v0.5.1, you can > get rid of the only sparse warning on Linux (assuming you don't > build with NO_REGEX set), by using the -Wno-memcpy-max-count option; > I have the following set in

RE: [PATCH] doc: clarify triangular workflow

2017-12-07 Thread BENSOUSSAN--BOHM DANIEL p1507430
>The document starts with >This document attempts to write down and motivate some of the >workflow elements used for `git.git` itself. Many ideas apply >in general, though the full workflow is rarely required for >smaller projects with fewer people involved. >and makes me wonder (note:

Re: Assalam Alaikum

2017-12-07 Thread Eiman Yousef M A Al-muzafar
Assalam Alaikum, I am Eiman Yousef M A Al-muzafar, a Muslim woman from Qatar, I am contacting you regarding a relationship of trust and confidence for an inheritance. Please contact me on my private email for more details: eimanyou...@hotmail.com

Re: [PATCH] doc: clarify triangular workflow

2017-12-07 Thread Matthieu Moy
BENSOUSSAN--BOHM DANIEL p1507430 writes: >>The document starts with > > >This document attempts to write down and motivate some of the > >workflow elements used for `git.git` itself. Many ideas apply > >in general, though the full workflow is

Re: [PATCH v4] send-email: extract email-parsing code into a subroutine

2017-12-07 Thread Ævar Arnfjörð Bjarmason
On Thu, Dec 07 2017, Matthieu Moy jotted: > Not terribly important, but your patch has trailing newlines. "git diff > --staged --check" to see them. More below. > > PAYRE NATHAN p1508475 writes: > >> the part of code which parses the header a last time to prepare

Re: [PATCH v5 2/2] launch_editor(): indicate that Git waits for user input

2017-12-07 Thread Lars Schneider
> On 07 Dec 2017, at 17:30, Junio C Hamano wrote: > > Lars Schneider writes: > >>> Can you squash that if you like it? > > I thought you also had to update the log message that you forgot to? > > Here is the replacement I queued tentatively.

Re: [PATCH v5 2/2] launch_editor(): indicate that Git waits for user input

2017-12-07 Thread Lars Schneider
> On 07 Dec 2017, at 16:48, Lars Schneider wrote: > > >> On 07 Dec 2017, at 16:43, Junio C Hamano wrote: >> >> lars.schnei...@autodesk.com writes: >> ... > > How about this? > > fprintf(stderr, >

Re: [PATCH v5 2/2] launch_editor(): indicate that Git waits for user input

2017-12-07 Thread Junio C Hamano
Lars Schneider writes: >> Can you squash that if you like it? I thought you also had to update the log message that you forgot to? Here is the replacement I queued tentatively. -- >8 -- From: Lars Schneider Date: Thu, 7 Dec 2017 16:16:41

Re: [WIP 04/15] upload-pack: convert to a builtin

2017-12-07 Thread Johannes Schindelin
Hi Junio, On Wed, 6 Dec 2017, Junio C Hamano wrote: > Brandon Williams writes: > > > In order to allow for code sharing with the server-side of fetch in > > protocol-v2 convert upload-pack to be a builtin. > > > > Signed-off-by: Brandon Williams > > --- >

Re: git blame --reverse doesn't find line in HEAD

2017-12-07 Thread Nick Snyder
I built from source and was unable to find a git version where this has ever worked correctly. I wasn't able to compile and test versions older than 1.6.1. Confirmed not working: 2.15.1 2.13.6 (Apple Git-96) 2.0.0 1.7.0 1.6.3 1.6.2 1.6.1 I updated the https://github.com/nicksnyder/git-blame-bug

[PATCH v2 0/7] reroll of cc/skip-to-optional-val

2017-12-07 Thread Junio C Hamano
I'm sending out only the last three parts, as the changes necessary to 03/07 that incorrectly used the variant without _default() to overwrite options->prefix should be trivally obvious. 05/07 uses the _default() variant so that the caller can react differently to "--relative" from "--relative="

[PATCH v2 7/7] t4045: test 'diff --relative' for real

2017-12-07 Thread Junio C Hamano
The existing tests only checked how well -relative= work, without testing --relative (without any value). Signed-off-by: Junio C Hamano --- t/t4045-diff-relative.sh | 24 1 file changed, 20 insertions(+), 4 deletions(-) diff --git

[PATCH v2 6/7] t4045: reindent to make helpers readable

2017-12-07 Thread Junio C Hamano
Signed-off-by: Junio C Hamano --- t/t4045-diff-relative.sh | 95 +--- 1 file changed, 50 insertions(+), 45 deletions(-) diff --git a/t/t4045-diff-relative.sh b/t/t4045-diff-relative.sh index 3950f5034d..fefd2f3f81 100755 ---

[PATCH v2 5/7] diff: use skip-to-optional-val in parsing --relative

2017-12-07 Thread Junio C Hamano
Signed-off-by: Junio C Hamano --- diff.c | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/diff.c b/diff.c index cd032c6367..e99ac6ec8a 100644 --- a/diff.c +++ b/diff.c @@ -4563,11 +4563,10 @@ int diff_opt_parse(struct diff_options *options,

Re: What's cooking in git.git (Dec 2017, #01; Mon, 4)

2017-12-07 Thread Johannes Schindelin
Hi, On Wed, 6 Dec 2017, Lars Schneider wrote: > > > On 04 Dec 2017, at 22:46, Junio C Hamano wrote: > > > > > > * tb/check-crlf-for-safe-crlf (2017-11-27) 1 commit > > - convert: tighten the safe autocrlf handling > > > > The "safe crlf" check incorrectly triggered for

Re: [PATCH v5 2/2] launch_editor(): indicate that Git waits for user input

2017-12-07 Thread Lars Schneider
> On 07 Dec 2017, at 18:37, Kaartic Sivaraam wrote: > > On Thursday 07 December 2017 10:00 PM, Junio C Hamano wrote: >> + >> +if (print_waiting_for_editor) { >> +/* >> + * A dumb terminal cannot erase the line later

Re: [PATCH v5 2/2] launch_editor(): indicate that Git waits for user input

2017-12-07 Thread Kaartic Sivaraam
On Thursday 07 December 2017 10:00 PM, Junio C Hamano wrote: + + if (print_waiting_for_editor) { + /* +* A dumb terminal cannot erase the line later on. Add a +* newline to separate the hint from subsequent

Re: [PATCH v5 2/2] launch_editor(): indicate that Git waits for user input

2017-12-07 Thread Lars Schneider
> On 07 Dec 2017, at 16:43, Junio C Hamano wrote: > > lars.schnei...@autodesk.com writes: > >> +if (print_waiting_for_editor) { >> +fprintf(stderr, >> +_("hint: Waiting for your editor to close the >> file... "));

What's cooking in git.git (Dec 2017, #02; Thu, 7)

2017-12-07 Thread Junio C Hamano
Here are the topics that have been cooking. Commits prefixed with '-' are only in 'pu' (proposed updates) while commits prefixed with '+' are in 'next'. The ones marked with '.' do not appear in any of the integration branches, but I am still holding onto them. You can find the changes

Re: git commit file completion recently broke

2017-12-07 Thread Jacob Keller
On Thu, Dec 7, 2017 at 7:24 AM, Junio C Hamano wrote: > Christian Couder writes: > >>> I do think it may make sense for >>> the "short" one to use NULL, like: >>> >>> skip_to_optional_val(arg, "--relative, ) >>> >>> but maybe some other callers

Re: [PATCH v2] diff: fix --relative without arguments

2017-12-07 Thread Jacob Keller
On Thu, Dec 7, 2017 at 7:26 AM, Junio C Hamano wrote: > Jacob Keller writes: > >> From: Jacob Keller >> >> Recently, commit f7923a5ece00 ("diff: use skip_to_optional_val()", >> 2017-12-04) changed how we parsed some diff

[PATCH] diff: add tests for --relative without optional prefix value

2017-12-07 Thread Jacob Keller
From: Jacob Keller We already have tests for --relative, but they currently only test when a prefix has been provided. This fails to test the case where --relative by itself should use the current directory as the prefix. Teach the check_$type functions to take a

Re: [PATCH] diff: add tests for --relative without optional prefix value

2017-12-07 Thread Junio C Hamano
Jacob Keller writes: > for type in diff numstat stat raw; do > - check_$type file2 --relative=subdir/ > - check_$type file2 --relative=subdir > - check_$type dir/file2 --relative=sub > + check_$type . file2 --relative=subdir/ > + check_$type . file2

Re: [PATCH v6 03/12] fsck: support refs pointing to promisor objects

2017-12-07 Thread Brandon Williams
On 12/05, Jeff Hostetler wrote: > From: Jonathan Tan > > Teach fsck to not treat refs referring to missing promisor objects as an > error when extensions.partialclone is set. > > For the purposes of warning about no default refs, such refs are still > treated as

Re: [WIP 08/15] connect: discover protocol version outside of get_remote_heads

2017-12-07 Thread Junio C Hamano
Brandon Williams writes: > While we could wrap the preamble into a function it sort of defeats the > purpose since you want to be able to call different functions based on > the protocol version you're speaking. That way you can have hard > separations between the code paths

Re: [WIP 06/15] transport: use get_refs_via_connect to get refs

2017-12-07 Thread Brandon Williams
On 12/06, Junio C Hamano wrote: > Brandon Williams writes: > > > Remove code duplication and use the existing 'get_refs_via_connect()' > > function to retrieve a remote's heads in 'fetch_refs_via_pack()' and > > 'git_transport_push()'. > > > > Signed-off-by: Brandon Williams

Re: [PATCH v2 5/7] diff: use skip-to-optional-val in parsing --relative

2017-12-07 Thread Jacob Keller
On Thu, Dec 7, 2017 at 9:30 AM, Junio C Hamano wrote: > Signed-off-by: Junio C Hamano > --- > diff.c | 7 +++ > 1 file changed, 3 insertions(+), 4 deletions(-) > > diff --git a/diff.c b/diff.c > index cd032c6367..e99ac6ec8a 100644 > --- a/diff.c > +++

Re: [PATCH v2 7/7] t4045: test 'diff --relative' for real

2017-12-07 Thread Jacob Keller
On Thu, Dec 7, 2017 at 9:30 AM, Junio C Hamano wrote: > The existing tests only checked how well -relative= work, > without testing --relative (without any value). > > Signed-off-by: Junio C Hamano > --- > t/t4045-diff-relative.sh | 24

Re: [PATCH v6 03/12] fsck: support refs pointing to promisor objects

2017-12-07 Thread Brandon Williams
On 12/07, Jonathan Tan wrote: > On Thu, 7 Dec 2017 11:18:52 -0800 > Brandon Williams wrote: > > > Instead of requiring that every test first removes 'repo', maybe you > > want to have each test do its own cleanup by adding in > > 'test_when_finished' lines to do the removals?

Re: [WIP 08/15] connect: discover protocol version outside of get_remote_heads

2017-12-07 Thread Junio C Hamano
Brandon Williams writes: > @@ -193,7 +195,17 @@ int cmd_fetch_pack(int argc, const char **argv, const > char *prefix) > if (!conn) > return args.diag_url ? 0 : 1; > } > - get_remote_heads(fd[0], NULL, 0, , 0, NULL, ); > + > +

Re: [WIP 08/15] connect: discover protocol version outside of get_remote_heads

2017-12-07 Thread Brandon Williams
On 12/07, Junio C Hamano wrote: > Brandon Williams writes: > > > @@ -193,7 +195,17 @@ int cmd_fetch_pack(int argc, const char **argv, const > > char *prefix) > > if (!conn) > > return args.diag_url ? 0 : 1; > > } > > -

Re: [PATCH v6 03/12] fsck: support refs pointing to promisor objects

2017-12-07 Thread Jonathan Tan
On Thu, 7 Dec 2017 11:18:52 -0800 Brandon Williams wrote: > Instead of requiring that every test first removes 'repo', maybe you > want to have each test do its own cleanup by adding in > 'test_when_finished' lines to do the removals? Just a thought. If "test_when_finished"

Re: [PATCH v6 09/12] fixup: sha1_file: convert gotos to break/continue

2017-12-07 Thread Brandon Williams
On 12/05, Jeff Hostetler wrote: > From: Jeff Hostetler > I'm a fan of eliminating looping goto statements. I understand their need for doing cleanup, but I think they should be reserved for that specific case. Thanks for cleaning this up! > Signed-off-by: Jeff

[PATCH] RelNotes/2.16: Fix submodule recursing argument

2017-12-07 Thread Stefan Beller
Some commands take a plain `--recursive` flag as an indication to recurse into submodules, git-clone is a notable user facing example, an internal example is in builtin/submodule--helper. Other commands such as git-merge take the `--recursive` flag to indicate recursing in their specific area of

[PATCH] fmt-merge-msg: avoid leaking strbuf in shortlog()

2017-12-07 Thread René Scharfe
Use string_list_append_nodup() instead of string_list_append() to hand over ownership of a detached strbuf and thus avoid leaking its memory. Signed-off-by: Rene Scharfe --- builtin/fmt-merge-msg.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git

Re: [PATCH] RelNotes/2.16: Fix submodule recursing argument

2017-12-07 Thread Junio C Hamano
Stefan Beller writes: > Junio, feel free to just squash this into a future update > of the release notes. > ... > - * "git checkout --recursive" may overwrite and rewind the history of > + * "git checkout --recurse-submodules" may overwrite and rewind the history > of

Re: [PATCH] diff: add tests for --relative without optional prefix value

2017-12-07 Thread Jacob Keller
On Thu, Dec 7, 2017 at 11:17 AM, Junio C Hamano wrote: > Jacob Keller writes: > >> for type in diff numstat stat raw; do >> - check_$type file2 --relative=subdir/ >> - check_$type file2 --relative=subdir >> - check_$type dir/file2

Re: Feature request: Reduce amount of diff in patch

2017-12-07 Thread Stefan Beller
On Tue, Nov 28, 2017 at 8:09 AM, KES wrote: > Hi. > > I get often patches which can be minimized: > > @@ -60,11 +64,8 @@ sub _get_filter { > address=> { -like => \[ '?', "%$search%" ] }, > company=> { -like => \[ '?', "%$search%" ] }, >

[PATCH] am: release strbuf after use in split_mail_mbox()

2017-12-07 Thread René Scharfe
Signed-off-by: Rene Scharfe --- builtin/am.c | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/builtin/am.c b/builtin/am.c index 02853b3e05..1ac044da2e 100644 --- a/builtin/am.c +++ b/builtin/am.c @@ -708,6 +708,7 @@ static int split_mail_mbox(struct

Re: What's cooking in git.git (Dec 2017, #01; Mon, 4)

2017-12-07 Thread Todd Zullinger
Johannes Schindelin wrote: That is not the only thing going wrong: https://travis-ci.org/git/git/builds/312551566 It would seem that t9001 is broken on Linux32, t5616 is broken on macOS, and something really kinky is going on with the GETTEXT_POISON text, as it seems to just abort

Re: Feature request: Reduce amount of diff in patch

2017-12-07 Thread Junio C Hamano
Stefan Beller writes: > On Tue, Nov 28, 2017 at 8:09 AM, KES wrote: > ... >> May you please fix the git to generate minimized patches? > > You can use a different diff algorithm. > ... > Soon we'll have another diff algorithm "anchor" that tries to > keep