Re: [PATCH 3/4] submodule--helper: fix BUG message in ensure_core_worktree

2018-12-07 Thread Junio C Hamano
wanted to > replay the series on top of it to reach the goal of having `core.worktree` > correctly set when the submodules worktree is present, and unset when the > worktree is not present. > > The replay resulted in a strange merge conflict highlighting that > the BUG m

Re: bug: git fetch reports too many unreachable loose objects

2018-12-07 Thread Elijah Newren
c` does not fix the problem, and appears to do > nothing in this situation: > git gc > > > According to the `git fetch` output, the `git help gc` docs, and the > `git help prune` docs, I don't think I shouldn't ever have to run `git > prune` manually, so this behavior see

bug: git fetch reports too many unreachable loose objects

2018-12-07 Thread Josh Wolfe
ver have to run `git prune` manually, so this behavior seems like a bug to me. Please correct me if this is expected behavior. In case anyone's wondering why I'm creating unreachable loose objects, here's the usecase: https://stackoverflow.com/a/50403179/367916 . I would love a first-class sol

[PATCH 3/4] submodule--helper: fix BUG message in ensure_core_worktree

2018-12-07 Thread Stefan Beller
of having `core.worktree` correctly set when the submodules worktree is present, and unset when the worktree is not present. The replay resulted in a strange merge conflict highlighting that the BUG message was not changed in 74d4731da1 (submodule--helper: replace connect-gitdir-workingtree by ensure-cor

Re: [BUG REPORT] Git does not correctly replay bisect log

2018-12-06 Thread Christian Couder
which calls `bisect_next` which calls `git bisect--helper --next-all` which checks the merge bases. I think it is a bug. `git bisect replay` is right to only update the references (ref/bisect/*) and not to compute and checkout the best commit to test at each step except at the end, but it sh

behaviour of git-blame -M -C (maybe a bug?)

2018-12-06 Thread dmg
0 -0800 150) DECL|function|tpm_common_open (struct file * file,struct tpm_chip * chip,struct file_priv * priv) now blame assigns the lines 29, 30, 53 and 54 to commit 391adba4 refactor!!! This is what I think is a bug. (by the way, the changes made in this last commit were between 28 and 150) than

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-12-06 Thread Frank Schäfer
Am 06.12.18 um 01:58 schrieb Junio C Hamano: > Frank Schäfer writes: > >> Just to be sure that I'm not missing anything here: >> What's your definition of "LF in repository, CRLF in working tree" in >> terms of config parameters ? > :::Documentation/config/core.txt::: > > core.autocrlf:: >

Re: [BUG REPORT] Git does not correctly replay bisect log

2018-12-06 Thread Lukáš Krejčí
On Thu, 2018-12-06 at 17:31 +0100, Christian Couder wrote: > > When Git replays the bisect log, it only updates refs/bisect/bad, > > refs/bisect/good-*, refs/bisect/skip-* and reconstructs the log in > > .git/BISECT_LOG. After that check_good_are_ancestors_of_bad() verifies > > that all good

Re: [BUG REPORT] Git does not correctly replay bisect log

2018-12-06 Thread Christian Couder
Hi, On Thu, Dec 6, 2018 at 3:43 PM Lukáš Krejčí wrote: > > Hello again, > > after looking into this today, I'm not sure if this can be considered a > bug - it's just that I expected Git to check out the exact commit to > test that was there before resetting the bisect. That

Re: [BUG REPORT] Git does not correctly replay bisect log

2018-12-06 Thread Lukáš Krejčí
Hello again, after looking into this today, I'm not sure if this can be considered a bug - it's just that I expected Git to check out the exact commit to test that was there before resetting the bisect. That made me uncertain whether Git restored the correct state. When I looked at what Git

Bug: git add --patch does not honor "diff.noprefix"

2018-12-06 Thread Christian Weiske
Hi, When running "git add -p" on git version 2.19.2 and "diff.noprefix" set to true, it still shows the "a/" and "b/" prefixes. This issue has been reported in 2016 already[1], but is still there in 2.19.2. [1] https://public-inbox.org/git/e1d7329a-a54b-4d09-a72a-62eca8005...@gmail.com/T/ --

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-12-05 Thread Junio C Hamano
Frank Schäfer writes: > Just to be sure that I'm not missing anything here: > What's your definition of "LF in repository, CRLF in working tree" in > terms of config parameters ? :::Documentation/config/core.txt::: core.autocrlf:: Setting this variable to "true" is the same as setting

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-12-05 Thread Johannes Sixt
Am 05.12.18 um 20:29 schrieb Frank Schäfer: Am 02.12.18 um 22:22 schrieb Johannes Sixt: Am 02.12.18 um 20:31 schrieb Frank Schäfer: With other words: "If CR comes immediately before a LF, do the following with *all* lines: after the CR if eol=lf but do not after the CR if eol=crlf." Why?

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-12-05 Thread Frank Schäfer
Am 03.12.18 um 02:15 schrieb Junio C Hamano: > Frank Schäfer writes: > >> Hi Junio, >> >> Am 29.11.18 um 03:11 schrieb Junio C Hamano: >> [...] >>> This was misspoken a bit. Let's revise it to >>> >>> When producing a colored output (not limited to whitespace >>> error coloring of diff

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-12-05 Thread Frank Schäfer
Am 02.12.18 um 22:22 schrieb Johannes Sixt: > Am 02.12.18 um 20:31 schrieb Frank Schäfer: >> With other words: >> "If CR comes immediately before a LF, do the following with *all* lines: >> after the CR if eol=lf but do not after the CR if >> eol=crlf." > > Why? It is the pager's duty to

Re: [BUG REPORT] Git does not correctly replay bisect log

2018-12-04 Thread Lukáš Krejčí
On Tue, 2018-12-04 at 13:01 +0100, Christian Couder wrote: > To debug I think it would be interesting to see the output of the > following commands just before we get different results: > > git for-each-ref 'refs/bisect/*' > > and > > git log -1 --format=oneline > I placed the following

Re: [BUG REPORT] Git does not correctly replay bisect log

2018-12-04 Thread Christian Couder
On Tue, Dec 4, 2018 at 12:20 PM Lukáš Krejčí wrote: > > On Tue, 2018-12-04 at 12:04 +0100, Christian Couder wrote: > > > > Could you try to check that? And first could you give us the output of: > > > > git merge-base 5b394b2ddf0347bef56e50c69a58773c94343ff3 > >

Re: [BUG REPORT] Git does not correctly replay bisect log

2018-12-04 Thread Lukáš Krejčí
(I'm sorry about the formatting, here's the message again.) Executing git bisect replay reaches a different commit than the one that is obtained by running the commands from the bisect log manually. Distribution: Arch Linux git: 2.19.2-1 perl: 5.28.1-1 pcre2: 10.32-1 expat: 2.2.6-1 perl-error:

Re: [BUG REPORT] Git does not correctly replay bisect log

2018-12-04 Thread Lukáš Krejčí
On Tue, 2018-12-04 at 12:04 +0100, Christian Couder wrote: > > Could you try to check that? And first could you give us the output of: > > git merge-base 5b394b2ddf0347bef56e50c69a58773c94343ff3 > 94710cac0ef4ee177a63b5227664b38c95bbf703 $ git merge-base 5b394b2ddf0347bef56e50c69a58773c94343ff3

Re: [BUG REPORT] Git does not correctly replay bisect log

2018-12-04 Thread Christian Couder
On Tue, Dec 4, 2018 at 10:53 AM Lukáš Krejčí wrote: > > Executing git bisect replay reaches a different commit than > the one that is obtained by running the commands from the bisect log manually. > $ git bisect replay /var/tmp/git-bisect.log > We are not bisecting. > Bisecting: a merge base

[BUG REPORT] Git does not correctly replay bisect log

2018-12-04 Thread Lukáš Krejčí
Executing git bisect replay reaches a different commit than the one that is obtained by running the commands from the bisect log manually. Distribution: Arch Linux git: 2.19.2-1 perl: 5.28.1-1 pcre2: 10.32-1 expat: 2.2.6-1 perl-error: 0.17027-1 grep: 3.1-2 bash: 4.4.023-1 no system

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-12-02 Thread Junio C Hamano
Frank Schäfer writes: > Hi Junio, > > Am 29.11.18 um 03:11 schrieb Junio C Hamano: > [...] >> This was misspoken a bit. Let's revise it to >> >> When producing a colored output (not limited to whitespace >> error coloring of diff output) for contents that are not >> marked as

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-12-02 Thread Johannes Sixt
Am 02.12.18 um 20:31 schrieb Frank Schäfer: Am 29.11.18 um 03:11 schrieb Junio C Hamano: [...] This was misspoken a bit. Let's revise it to When producing a colored output (not limited to whitespace error coloring of diff output) for contents that are not marked as

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-12-02 Thread Frank Schäfer
Hi Junio, Am 29.11.18 um 03:11 schrieb Junio C Hamano: [...] > This was misspoken a bit. Let's revise it to > > When producing a colored output (not limited to whitespace > error coloring of diff output) for contents that are not > marked as eol=crlf (and other historical

Re: [bug report] git-gui child windows are blank

2018-11-29 Thread Kenn Sebesta
gt; > > v2.19.2, installed from brew on macOS Mojave 14.2.1. > > > > > > `git-gui` is my much beloved go-to tool for everything git. > > > Unfortunately, on my new Macbook Air it seems to have a bug. When I > > > first load the program, the parent window popula

Re: [bug report] git-gui child windows are blank

2018-11-29 Thread Eric Sunshine
On Wed, Nov 28, 2018 at 2:29 PM Stefan Beller wrote: > On Wed, Nov 28, 2018 at 6:13 AM Kenn Sebesta wrote: > > v2.19.2, installed from brew on macOS Mojave 14.2.1. > > > > `git-gui` is my much beloved go-to tool for everything git. > > Unfortunately, on my new Macbook

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-11-28 Thread Junio C Hamano
Johannes Sixt writes: > Am 27.11.18 um 00:31 schrieb Junio C Hamano: >> Johannes Sixt writes: >>> Am 26.11.18 um 04:04 schrieb Junio C Hamano: >>> ... this goes too far, IMO. It is the pager's task to decode control >>> characters. >> >> It was tongue-in-cheek suggestion to split a CR into

Re: [BUG REPORT] t5322: demonstrate a pack-objects bug

2018-11-28 Thread Derrick Stolee
ally, when copying a directory across sibling directories (see test case), the new logic would accidentally send that object as an extra. However, I found a bug in the existing logic. The included test demonstrates this during the final 'git index-pack' call. It fails with the message 'fatal

[BUG REPORT] t5322: demonstrate a pack-objects bug

2018-11-28 Thread Derrick Stolee
irectories (see test case), the new logic would accidentally send that object as an extra. However, I found a bug in the existing logic. The included test demonstrates this during the final 'git index-pack' call. It fails with the message 'fatal: pack has 1 unresolved delta' It i

Re: [bug report] git-gui child windows are blank

2018-11-28 Thread Stefan Beller
On Wed, Nov 28, 2018 at 6:13 AM Kenn Sebesta wrote: > > v2.19.2, installed from brew on macOS Mojave 14.2.1. > > `git-gui` is my much beloved go-to tool for everything git. > Unfortunately, on my new Macbook Air it seems to have a bug. When I > first load the program, the paren

[bug report] git-gui child windows are blank

2018-11-28 Thread Kenn Sebesta
v2.19.2, installed from brew on macOS Mojave 14.2.1. `git-gui` is my much beloved go-to tool for everything git. Unfortunately, on my new Macbook Air it seems to have a bug. When I first load the program, the parent window populates normally with the stage/unstaged and diff panes. However, when I

Re: [PATCH] tests: avoid syntax triggering old dash bug

2018-11-27 Thread Torsten Bögershausen
On Wed, Nov 28, 2018 at 01:47:41AM +, brian m. carlson wrote: > On Tue, Nov 27, 2018 at 05:42:53PM +0100, Ævar Arnfjörð Bjarmason wrote: > > Avoid a bug in dash that's been fixed ever since its > > ec2c84d ("[PARSER] Fix clobbering of checkkwd", 2011-03-15)[1] fir

Re: [PATCH] tests: avoid syntax triggering old dash bug

2018-11-27 Thread Junio C Hamano
Eric Sunshine writes: > On Tue, Nov 27, 2018 at 11:43 AM Ævar Arnfjörð Bjarmason > wrote: >> Avoid a bug in dash that's been fixed ever since its >> ec2c84d ("[PARSER] Fix clobbering of checkkwd", 2011-03-15)[1] first >> released with dash v0.5.7 in July 20

Re: [PATCH] tests: avoid syntax triggering old dash bug

2018-11-27 Thread brian m. carlson
On Tue, Nov 27, 2018 at 05:42:53PM +0100, Ævar Arnfjörð Bjarmason wrote: > Avoid a bug in dash that's been fixed ever since its > ec2c84d ("[PARSER] Fix clobbering of checkkwd", 2011-03-15)[1] first > released with dash v0.5.7 in July 2011. > > This fixes 1/2 test

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-11-27 Thread Frank Schäfer
Am 27.11.18 um 19:15 schrieb Johannes Sixt: > Am 27.11.18 um 00:31 schrieb Junio C Hamano: >> Johannes Sixt writes: >>> Am 26.11.18 um 04:04 schrieb Junio C Hamano: >>> ... this goes too far, IMO. It is the pager's task to decode control >>> characters. >> >> It was tongue-in-cheek suggestion

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-11-27 Thread Frank Schäfer
Am 27.11.18 um 00:31 schrieb Junio C Hamano: > Johannes Sixt writes: > >> Am 26.11.18 um 04:04 schrieb Junio C Hamano: >>> That does not sound right. I would understand it if both lines >>> showed ^M at the end, and only the one on the postimage line had it >>> highlighted as a

Re: [PATCH] tests: avoid syntax triggering old dash bug

2018-11-27 Thread Ævar Arnfjörð Bjarmason
On Tue, Nov 27 2018, Eric Sunshine wrote: > On Tue, Nov 27, 2018 at 11:43 AM Ævar Arnfjörð Bjarmason > wrote: >> Avoid a bug in dash that's been fixed ever since its >> ec2c84d ("[PARSER] Fix clobbering of checkkwd", 2011-03-15)[1] first >> released with das

Re: [PATCH] tests: avoid syntax triggering old dash bug

2018-11-27 Thread Eric Sunshine
On Tue, Nov 27, 2018 at 11:43 AM Ævar Arnfjörð Bjarmason wrote: > Avoid a bug in dash that's been fixed ever since its > ec2c84d ("[PARSER] Fix clobbering of checkkwd", 2011-03-15)[1] first > released with dash v0.5.7 in July 2011. Perhaps enhance the commit message to

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-11-27 Thread Johannes Sixt
Am 27.11.18 um 00:31 schrieb Junio C Hamano: Johannes Sixt writes: Am 26.11.18 um 04:04 schrieb Junio C Hamano: ... this goes too far, IMO. It is the pager's task to decode control characters. It was tongue-in-cheek suggestion to split a CR into caret-em on our end, but we'd get essentially

[PATCH] tests: avoid syntax triggering old dash bug

2018-11-27 Thread Ævar Arnfjörð Bjarmason
Avoid a bug in dash that's been fixed ever since its ec2c84d ("[PARSER] Fix clobbering of checkkwd", 2011-03-15)[1] first released with dash v0.5.7 in July 2011. This fixes 1/2 tests failing on Debian Lenny & Squeeze. The other failure is due to 1b42f45255 ("git-svn: apply &q

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-11-26 Thread Junio C Hamano
Johannes Sixt writes: > Am 26.11.18 um 04:04 schrieb Junio C Hamano: >> >> That does not sound right. I would understand it if both lines >> showed ^M at the end, and only the one on the postimage line had it >> highlighted as a trailing-whitespace. > > I agree that this is a (small?) weakness.

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-11-26 Thread Johannes Sixt
Am 26.11.18 um 04:04 schrieb Junio C Hamano: It appears to me that what Frank sees is not "^M highlighted for whitespace breakage appears only on postimage lines, while ^M is shown but not highlighted on preimage lines". My reading of the above is "Not just without highlight, ^M is just *NOT*

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-11-25 Thread Junio C Hamano
Johannes Sixt writes: > But incorrect whitespace is never highlighted in removed lines, why > should CR be an exception? > ... > Same here for other cases, for example > > -something > +something > > will not have on obvious indicator that whitespace was corrected. All correct, but misses one

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-11-25 Thread brian m. carlson
On Sun, Nov 25, 2018 at 03:03:11PM +0100, Frank Schäfer wrote: > Am 24.11.18 um 23:07 schrieb Johannes Sixt: > > I don't think that there is anything to fix. If you have a file with > > CRLF in it, but you did not declare to Git that CRLF is the expected > > end-of-line indicator, then the CR *is*

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-11-25 Thread Johannes Sixt
Am 25.11.18 um 15:03 schrieb Frank Schäfer: Am 24.11.18 um 23:07 schrieb Johannes Sixt: I don't think that there is anything to fix. If you have a file with CRLF in it, but you did not declare to Git that CRLF is the expected end-of-line indicator, then the CR *is* trailing whitespace (because

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-11-25 Thread Frank Schäfer
Am 24.11.18 um 23:07 schrieb Johannes Sixt: > I don't think that there is anything to fix. If you have a file with > CRLF in it, but you did not declare to Git that CRLF is the expected > end-of-line indicator, then the CR *is* trailing whitespace (because > the line ends at LF), and 'git diff'

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-11-24 Thread Johannes Sixt
Am 24.11.18 um 15:51 schrieb Frank Schäfer: Am 23.11.18 um 22:47 schrieb Johannes Sixt: Am 23.11.18 um 19:19 schrieb Frank Schäfer: The CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF. It shows up as expected in '-' lines when the ending of the

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-11-24 Thread Torsten Bögershausen
On Sat, Nov 24, 2018 at 03:51:26PM +0100, Frank Schäfer wrote: [] > > Hmm... is CR-only line termination supported at all ? > E.g. 'eol' can be set to 'lf' or 'crlf' but not 'cr'... > No, CR-only is not supported, because: Nobody was implementing it, and that is probably because the only

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-11-24 Thread Frank Schäfer
Am 23.11.18 um 22:47 schrieb Johannes Sixt: > Am 23.11.18 um 19:19 schrieb Frank Schäfer: >> The CR marker ^M doesn't show up in '-' lines of diffs when the ending >> of the removed line is CR+LF. >> It shows up as expected in '-' lines when the ending of the removed line >> is CR only. >> It also

Re: [PATCH v4 0/2] Fix scissors bug during merge conflict

2018-11-23 Thread Junio C Hamano
Denton Liu writes: > I just realised that there is a slight problem with the proposed change. > When we do a merge and there are no merge conflicts, at the end of the > merge, we get dropped into an editor with this text: > > Merge branch 'master' into new > > # Please enter a commit

Re: BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-11-23 Thread Johannes Sixt
Am 23.11.18 um 19:19 schrieb Frank Schäfer: The CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF. It shows up as expected in '-' lines when the ending of the removed line is CR only. It also always shows up as expected in '+' lines. Is your

BUG: CR marker ^M doesn't show up in '-' lines of diffs when the ending of the removed line is CR+LF

2018-11-23 Thread Frank Schäfer
: LF to CR+LF: @@ -1,2 +1,2 @@ -aaa +aaa^M  bbb   CR+LF to LF: @@ -1,2 +1,2 @@ -aaa    => BUG: should be -aaa^M +aaa  bbb CR to CR+LF: @@ -1 +1,2 @@ -aaa^Mbbb +aaa^M +bbb CR+LF to CR: @@ -1,2 +1 @@ -aaa    => BUG: should be -aaa^M -bbb +aaa^Mbbb LF to CR: @@ -1,2 +1 @@ -aaa -bb

Re: [PATCH v4 0/2] Fix scissors bug during merge conflict

2018-11-21 Thread Denton Liu
On Wed, Nov 21, 2018 at 06:38:20PM +0900, Junio C Hamano wrote: > Denton Liu writes: > > > Changes since V3: > > * Add patch to cleanup 'merge --squash c3 with c7' test in t7600 > > * Use test_i18ncmp instead of test_cmp to pass GETTEXT_POISON tests > > Queued. Thanks, both. I just

Re: [PATCH v4 0/2] Fix scissors bug during merge conflict

2018-11-21 Thread Junio C Hamano
Denton Liu writes: > Changes since V3: > * Add patch to cleanup 'merge --squash c3 with c7' test in t7600 > * Use test_i18ncmp instead of test_cmp to pass GETTEXT_POISON tests Queued. Thanks, both.

[PATCH v4 0/2] Fix scissors bug during merge conflict

2018-11-20 Thread Denton Liu
* Add passthrough options in pull * Add documentation for the new option * Add tests to ensure desired behaviour Changes since V2: * Merge both patches into one patch * Fix bug in help message printing logic Changes since V3: * Add patch to cleanup 'merge

Re: [PATCH] tests: send "bug in the test script" errors to the script's stderr

2018-11-20 Thread SZEDER Gábor
ors use descriptor 5, > > > > which goes to stdout. I'm not sure if those should actually be going to > > > > stderr (or if there's some TAP significance to those lines). > > > > > > I chose to send these messages to standard error, because they are, > > &g

Re: [PATCH] tests: send "bug in the test script" errors to the script's stderr

2018-11-20 Thread Jeff King
actually be going to > > > stderr (or if there's some TAP significance to those lines). > > > > I chose to send these messages to standard error, because they are, > > well, errors. TAP only cares about stdout, but by aborting the test > > script in BUG(), error()

Re: [PATCH] tests: send "bug in the test script" errors to the script's stderr

2018-11-20 Thread Jeff King
o those lines). > > I chose to send these messages to standard error, because they are, > well, errors. TAP only cares about stdout, but by aborting the test > script in BUG(), error() or die() we are already violating TAP anyway, > so I don't think it matters whether we send "b

Re: [PATCH] tests: send "bug in the test script" errors to the script's stderr

2018-11-19 Thread SZEDER Gábor
On Mon, Nov 19, 2018 at 02:44:32PM -0500, Jeff King wrote: > On Mon, Nov 19, 2018 at 02:13:26PM +0100, SZEDER Gábor wrote: > > > Send these "bug in the test script" error messages directly to the > > test scripts standard error and thus to the terminal, so those

Re: [PATCH] tests: send "bug in the test script" errors to the script's stderr

2018-11-19 Thread Jeff King
On Mon, Nov 19, 2018 at 02:13:26PM +0100, SZEDER Gábor wrote: > Send these "bug in the test script" error messages directly to the > test scripts standard error and thus to the terminal, so those bugs > will be much harder to overlook. Instead of updating all ~20 s

[PATCH] tests: send "bug in the test script" errors to the script's stderr

2018-11-19 Thread SZEDER Gábor
Some of the functions in our test library check that they were invoked properly with conditions like this: test "$#" = 2 || error "bug in the test script: not 2 parameters to test-expect-success" If this particular condition is triggered, then 'error' will abort t

Re: [PATCH v3 0/1] Fix scissors bug during merge conflict

2018-11-17 Thread Junio C Hamano
Denton Liu writes: >> I wonder if this is what you really meant to have instead: >> >> >else if (cleanup_mode == COMMIT_MSG_CLEANUP_SCISSORS && >> > - whence == FROM_COMMIT) >> > - wt_status_add_cut_line(s->fp); >> > + whence ==

[PATCH v3 0/1] Fix scissors bug during merge conflict

2018-11-17 Thread Denton Liu
being removed is now silenced in both cases. Changes since V1: * Only check MERGE_MSG for a scissors line instead of all prepended files * Make a variable static in merge where appropriate * Add passthrough options in pull * Add documentation for the

[PATCH v2 0/2] Fix scissors bug during merge conflict

2018-11-16 Thread Denton Liu
Thanks for your feedback, Junio. I tried to reroll the patch by adding another option into the MERGE_MODE file but unfortunately, it didn't work completely because doing `merge --squash` doesn't produce a MERGE_MODE. In addition to this, because of the way merge and commit were structured, I

Re: [PATCH v2 1/1] config: report a bug if git_dir exists without commondir

2018-11-14 Thread Jeff King
g_options *opts, > > if (opts->commondir) > repo_config = mkpathdup("%s/config", opts->commondir); > + else if (opts->git_dir) > + BUG("git_dir without commondir"); Yeah, I think this is the right thing to do. Thanks! -Peff

[PATCH v2 1/1] config: report a bug if git_dir exists without commondir

2018-11-14 Thread Johannes Schindelin via GitGitGadget
f (opts->git_dir) + BUG("git_dir without commondir"); else repo_config = NULL; -- gitgitgadget

Re: [RFC PATCH 0/2] Fix scissors bug during merge conflict

2018-11-14 Thread Denton Liu
On Wed, Nov 14, 2018 at 04:52:59PM +0900, Junio C Hamano wrote: > Denton Liu writes: > > > With this fix, the message becomes the following: > > > > Merge branch 'master' into new > > > > # >8 > > # Do not modify or remove the line

Re: [RFC PATCH 0/2] Fix scissors bug during merge conflict

2018-11-13 Thread Junio C Hamano
Denton Liu writes: > With this fix, the message becomes the following: > > Merge branch 'master' into new > > # >8 > # Do not modify or remove the line above. > # Everything below it will be ignored. > # > #

[RFC PATCH 0/2] Fix scissors bug during merge conflict

2018-11-13 Thread Denton Liu
I discovered a bug in Git a while ago where if one is using commit.cleanup = scissors, if making a commit after a merge conflict, the scissors line will be placed after the `Conflicts:` section. As a result, a careless Git user (e.g. me) may accidentally commit the `Conflicts:` section. Here

Re: [PATCH 1/5] rebase -r: demonstrate bug with conflicting merges

2018-11-13 Thread Junio C Hamano
Johannes Schindelin writes: > You misunderstand. In this case it is crucial to read the regression test > first. The fix does not make much sense before one understands the > condition under which the order of the code statements matters. I am not sure what you mean. It sounds as if you want

Re: [PATCH 1/5] rebase -r: demonstrate bug with conflicting merges

2018-11-13 Thread Johannes Schindelin
Hi Junio, On Tue, 13 Nov 2018, Junio C Hamano wrote: > Johannes Schindelin writes: > > >> For a trivially small change/fix like this, it is OK and even > >> preferrable to make 1+2 a single step, as applying t/ part only to > >> try to see the breakage (or "am"ing everything and then "diff | >

Re: [PATCH 1/5] rebase -r: demonstrate bug with conflicting merges

2018-11-13 Thread Junio C Hamano
Johannes Schindelin writes: >> For a trivially small change/fix like this, it is OK and even >> preferrable to make 1+2 a single step, as applying t/ part only to >> try to see the breakage (or "am"ing everything and then "diff | >> apply -R" the part outside t/ for the same purpose) is easy

Re: [PATCH 1/5] rebase -r: demonstrate bug with conflicting merges

2018-11-13 Thread Johannes Schindelin
test_must_fail git rev-parse --verify HEAD^2 && > > Even if we made an octopus by mistake, the above will catch it, > which is good. > > > + test_path_is_missing .git/MERGE_HEAD > > +' > > + > > test_done > > And from the proposed log message, I am reading that the last two > things (i.e. resulting tip is a child with a single parent and there > is no leftover MERGE_HEAD file) fail without the fix. > > This is enough material to convince me or anybody that the bug is > worth fixing. Thanks for being careful noticing a glitch during > your real (and otherwise unrelated to the bug) work and following > through. >

Re: [PATCH 1/5] rebase -r: demonstrate bug with conflicting merges

2018-11-12 Thread Junio C Hamano
e --continue && > + test_must_fail git rev-parse --verify HEAD^2 && Even if we made an octopus by mistake, the above will catch it, which is good. > + test_path_is_missing .git/MERGE_HEAD > +' > + > test_done And from the proposed log message, I am readi

[PATCH 1/5] rebase -r: demonstrate bug with conflicting merges

2018-11-12 Thread Johannes Schindelin via GitGitGadget
From: Johannes Schindelin When calling `merge` on a branch that has already been merged, that `merge` is skipped quietly, but currently a MERGE_HEAD file is being left behind and will then be grabbed by the next `pick` (that did not want to create a *merge* commit). Demonstrate this.

Re: BUG REPORT: git clone of non-existent repository results in request for credentials

2018-11-11 Thread Federico Lucifredi
g websites. E.g. here's two issues for fixing this > on GitLab: > > https://gitlab.com/gitlab-org/gitlab-ce/issues/50201 > https://gitlab.com/gitlab-org/gitlab-ce/issues/50660 > > These hosting platforms are intentionally producing bad error messages > to not leak information, as

Re: BUG REPORT: git clone of non-existent repository results in request for credentials

2018-11-11 Thread Ævar Arnfjörð Bjarmason
. So I doubt it's something they'll ever change, the bug I have open with this on GitLab is to make this configurable for privately run instances.

BUG REPORT: git clone of non-existent repository results in request for credentials

2018-11-11 Thread Federico Lucifredi
git clone of non-existent repository results in request for credentials REPRODUCING: sudo apt install git git clone https://github.com/xorbit/LiFePo4owered-Pi.git#this repo does not exist Git will then prompt for username and password on Github. I can see a valid data-leak concern (one

[PATCH v3 13/16] parse-options.c: turn some die() to BUG()

2018-11-09 Thread Nguyễn Thái Ngọc Duy
100644 --- a/parse-options.c +++ b/parse-options.c @@ -197,7 +197,7 @@ static int get_value(struct parse_opt_ctx_t *p, return 0; default: - die("should not happen, someone must be hit on the forehead"); + BUG("opt->type %d

[PATCH v3 05/16] read-cache.c: turn die("internal error") to BUG()

2018-11-09 Thread Nguyễn Thái Ngọc Duy
cache_entry *ce, struct stat *st) changed |= DATA_CHANGED; return changed; default: - die("internal error: ce_mode is %o", ce->ce_mode); + BUG("unsupported ce_mode: %o", ce->ce_mode);

[PATCH v3 09/16] remote.c: turn some error() or die() to BUG()

2018-11-09 Thread Nguyễn Thái Ngọc Duy
The first error, "internal error", is clearly a BUG(). The second two are meant to catch calls with invalid parameters and should never happen outside the test suite. Signed-off-by: Nguyễn Thái Ngọc Duy --- remote.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)

Bug: git-svn clone --preserve-empty-dirs fail - couldn't truncate file at /usr/share/perl5/Git.pm line 1337.

2018-11-06 Thread Georg Tsakumagos
ted. Also no problem if the svn dump is filtered with "svndumpfilter --drop-empty-revs" before load into a fresh repo. I'll be able to provide the dump for further investigations. I would send it on demand. I'm able to reproduce the failure with the dump. It seemed many others had suffered f

Re: [PATCH v2 13/16] parse-options.c: turn some die() to BUG()

2018-11-05 Thread Junio C Hamano
gt; > default: > - die("should not happen, someone must be hit on the forehead"); > + BUG("opt->type %d should not happen", opt->type); > } > } OK, this should not happen. > @@ -424,7 +424,7 @@ void parse_options_start(struct par

Re: [PATCH v2 09/16] remote.c: turn some error() or die() to BUG()

2018-11-05 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > The first error, "internal error", is clearly a BUG(). The second two > are meant to catch calls with invalid parameters and should never > happen outside the test suite. Sounds as if it would happen inside test suites. I guess by "in

Re: [PATCH v2 05/16] read-cache.c: turn die("internal error") to BUG()

2018-11-05 Thread Junio C Hamano
ead-cache.c > +++ b/read-cache.c > @@ -316,7 +316,7 @@ static int ce_match_stat_basic(const struct cache_entry > *ce, struct stat *st) > changed |= DATA_CHANGED; > return changed; > default: > - die("internal error:

[PATCH v2 13/16] parse-options.c: turn some die() to BUG()

2018-11-05 Thread Nguyễn Thái Ngọc Duy
100644 --- a/parse-options.c +++ b/parse-options.c @@ -197,7 +197,7 @@ static int get_value(struct parse_opt_ctx_t *p, return 0; default: - die("should not happen, someone must be hit on the forehead"); + BUG("opt->type %d

[PATCH v2 09/16] remote.c: turn some error() or die() to BUG()

2018-11-05 Thread Nguyễn Thái Ngọc Duy
The first error, "internal error", is clearly a BUG(). The second two are meant to catch calls with invalid parameters and should never happen outside the test suite. Signed-off-by: Nguyễn Thái Ngọc Duy --- remote.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)

[PATCH v2 05/16] read-cache.c: turn die("internal error") to BUG()

2018-11-05 Thread Nguyễn Thái Ngọc Duy
cache_entry *ce, struct stat *st) changed |= DATA_CHANGED; return changed; default: - die("internal error: ce_mode is %o", ce->ce_mode); + BUG("unsupported ce_mode: %o", ce->ce_mode);

Re: [BUG?] protocol.version=2 sends HTTP "Expect" headers

2018-11-01 Thread Jeff King
On Thu, Nov 01, 2018 at 12:48:04AM +, brian m. carlson wrote: > > So a few questions: > > > > - is this a bug or not? I.e., do we still need to care about proxies > > that can't handle Expect? The original commit was from 2011. Maybe > > things are bet

Re: [BUG?] protocol.version=2 sends HTTP "Expect" headers

2018-10-31 Thread brian m. carlson
at's because rather than going > through post_rpc(), we push the stateless data through a proxy_state > struct. And in proxy_state_init(), when we set up the headers, we do not > disable curl's Expect handling. > > So a few questions: > > - is this a bug or not? I.e., do we st

[BUG?] protocol.version=2 sends HTTP "Expect" headers

2018-10-31 Thread Jeff King
ate struct. And in proxy_state_init(), when we set up the headers, we do not disable curl's Expect handling. So a few questions: - is this a bug or not? I.e., do we still need to care about proxies that can't handle Expect? The original commit was from 2011. Maybe things are better now. Or maybe th

Re: bug?: git grep HEAD with exclude in pathspec not taken into account

2018-10-27 Thread Duy Nguyen
On Wed, Oct 24, 2018 at 4:55 PM Christophe Bliard wrote: > > Hi, > > I observed an unexpected behavior while using git grep with both git > 2.19.1 and 2.14.3. Quick note. I confirm this is a bug in tree_entry_interesting() perhaps being over-optimistic. It'll take me more time

Re: Possible bug in referenced configuration file loading

2018-10-26 Thread Jeff King
On Fri, Oct 26, 2018 at 09:30:51AM +0200, Raphael Stolt wrote: > Configuration for global ignore patterns in ~/.config/git/config: > > [core] > excludesfile = .gitignore > > doesn't get looked up per default in ~/.config/git/ which might be > considered a bug as the

Possible bug in referenced configuration file loading

2018-10-26 Thread Raphael Stolt
Configuration for global ignore patterns in ~/.config/git/config: [core] excludesfile = .gitignore doesn't get looked up per default in ~/.config/git/ which might be considered a bug as the .gitignore file isn't loaded. It's only loaded when .gitignore is located in $HOME or explicitly

Bug: git log changes output depending on how the output is used

2018-10-25 Thread buckmartin
I noticed that the piped output still prints the (HEAD -> ) : git log --pretty=format:"%d*%B" --decorate-refs='refs/tags/*' *bar (tag: "123")*foo git log --pretty=format:"%d*%B" --decorate-refs='refs/tags/*' > tmp.tmp (HEAD -> branch)*bar (tag: "123")*foo I would expect the output

[PATCH v4 1/3] repack: point out a bug handling stale shallow info

2018-10-24 Thread Johannes Schindelin via GitGitGadget
From: Johannes Schindelin A `git fetch --prune` can turn previously-reachable objects unreachable, even commits that are in the `shallow` list. A subsequent `git repack -ad` will then unceremoniously drop those unreachable commits, and the `shallow` list will become stale. This means that when

Re: bug?: git grep HEAD with exclude in pathspec not taken into account

2018-10-24 Thread Christophe Bliard
6] fileB > > 1 file changed, 1 insertion(+) > > create mode 100644 fileB > > > git --no-pager grep foo HEAD -- ':!fileA' > > HEAD:fileB:foo is false+ > > > git --no-pager grep foo HEAD -- ':!fileB' > > HEAD:fileA:foo > > HEAD:fileB:foo is false+ >

Re: bug?: git grep HEAD with exclude in pathspec not taken into account

2018-10-24 Thread Duy Nguyen
, fileB appears in grep results but it should have > been excluded. > > If the HEAD parameter is removed, it works as expected: It's probably a bug. We have different code paths for matching things with or without HEAD, roughly speaking. I'll look into to this more on the weekend, unl

Re: bug?: git grep HEAD with exclude in pathspec not taken into account

2018-10-24 Thread Christophe Bliard
6410172300120130ustar00rootroot00foo fileB664000161336410172300120170ustar00rootroot00foo is false+ fileA can be excluded, but not fileB. Is it a bug? Thanks -- Christophe Bliard

Re: [PATCH v3 1/3] repack: point out a bug handling stale shallow info

2018-10-24 Thread Johannes Schindelin
Hi Junio, me again. I was wrong. On Wed, 24 Oct 2018, Johannes Schindelin wrote: > On Wed, 24 Oct 2018, Junio C Hamano wrote: > > > "Johannes Schindelin via GitGitGadget" > > writes: > > > > > +... > > > + d="$(git -C shallow-server rev-parse --verify D)" && > > > + git -C shallow-server

  1   2   3   4   5   6   7   8   9   10   >