Re: `git status` output is very misleading after a merge on a "detached HEAD"

2017-04-11 Thread Michael J Gruber
Am 11. April 2017 22:40:14 MESZ schrieb "Ævar Arnfjörð Bjarmason" : >On Tue, Apr 11, 2017 at 5:13 PM, Enis Bayramoğlu > wrote: >>> Well, what do you suggest as an alternative? >>> >>> Git tells you that you are in detached state and where you came from

Re: [PATCH v3 4/4] convert: add "status=delayed" to filter process protocol

2017-04-11 Thread Torsten Bögershausen
On 2017-04-11 21:50, Lars Schneider wrote: [] >> packet: git> command=smudge >> packet: git> pathname=path/testfile.dat >> packet: git> delay-id=1 >> packet: git> >> packet: git> CONTENT >> packet: git> >> packet: git<

Re: [PATCH v9 3/3] read-cache: speed up add_index_entry during checkout

2017-04-11 Thread Junio C Hamano
g...@jeffhostetler.com writes: > From: Jeff Hostetler > > Teach add_index_entry_with_check() and has_dir_name() > to see if the path of the new item is greater than the > last path in the index array before attempting to search > for it. > > During checkout,

Re: [PATCH v6] http.postbuffer: allow full range of ssize_t values

2017-04-11 Thread Junio C Hamano
Jeff King writes: >> The only unresolved issue was whether we can count on curl being new >> enough for CURLOPT_POSTFIELDSIZE_LARGE to be present. I say >> "unresolved" but it is resolved in my mind since git doesn't build and >> pass tests with such old versions of curl ---

Re: [PATCH] t6500: don't run detached auto gc at the end of the test script

2017-04-11 Thread Jeff King
On Wed, Apr 12, 2017 at 02:27:05AM +0200, SZEDER Gábor wrote: > >> I wonder if you could make it a general test-lib function, like: > >> > >> run_and_wait () { > >> # we read stdout from the child only for the side effect > >> # of waiting until all child sub-processes exit,

Re: Modifying a bare repo directly

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 10:35:17PM +0100, Julian Goacher wrote: > Thanks for the replies; is there anything that needs to be known about > concurrent updates on a repo when using plumbing commands? Concurrent writes to the object database are always safe (so hash-object, write-tree, commit-tree

Re: What's cooking in git.git (Apr 2017, #01; Tue, 11)

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 03:47:13PM -0700, Jonathan Nieder wrote: > Junio C Hamano wrote: > > > * jk/no-looking-at-dotgit-outside-repo-final (2016-10-26) 1 commit > > (merged to 'next' on 2017-02-27 at 7373a1b73d) > > + setup_git_env: avoid blind fall-back to ".git" > > > > This is the

[PATCH] ls-files: properly prepare submodule environment

2017-04-11 Thread Jacob Keller
From: Jacob Keller Since commit e77aa336f116 ("ls-files: optionally recurse into submodules", 2016-10-07) ls-files has known how to recurse into submodules when displaying files. Unfortunately this code does not work as expected. Initially, it produced results indicating

Re: [PATCH] t6500: don't run detached auto gc at the end of the test script

2017-04-11 Thread SZEDER Gábor
On Tue, Apr 11, 2017 at 11:32 PM, Johannes Sixt wrote: > Am 10.04.2017 um 19:01 schrieb Jeff King: >> >> I wonder if you could make it a general test-lib function, like: >> >> run_and_wait () { >> # we read stdout from the child only for the side effect >> # of

[PATCH 0/4] recursive submodules: git-reset!

2017-04-11 Thread Stefan Beller
Now that the BIG one has landed, e394fa01d6 (Merge branch 'sb/checkout-recurse-submodules', 2017-03-28), you would expect that teaching to recurse into submodules is easy for all the remaining working tree manipulations? It turns out it is. See the last patch how we teach git-reset to recurse

[PATCH 1/4] entry.c: submodule recursing: respect force flag correctly

2017-04-11 Thread Stefan Beller
In case of a non-forced worktree update, the submodule movement is tested in a dry run first, such that it doesn't matter if the actual update is done via the force flag. However for correctness, we want to give the flag is specified by the user. All callers have been inspected and updated if

[PATCH 3/4] submodule.c: harden submodule_move_head against broken submodules

2017-04-11 Thread Stefan Beller
Early on in submodule_move_head just after the check if the submodule is initialized, we need to check if the submodule is populated correctly. If the submodule is initialized but doesn't look like populated, this is a red flag and can indicate multiple sorts of failures: (1) The submodule may be

[PATCH 4/4] builtin/reset: add --recurse-submodules switch

2017-04-11 Thread Stefan Beller
git-reset is yet another working tree manipulator, which should be taught about submodules. One use case of "git-reset" is to reset to a known good state, and dropping commits that did not work as expected. In that case one of the expected outcomes from a hard reset would be to have broken

[PATCH 2/4] submodule.c: uninitialized submodules are ignored in recursive commands

2017-04-11 Thread Stefan Beller
This was an oversight when working on the working tree modifying commands recursing into submodules. To test for uninitialized submodules, introduce another submodule, that is uninitialized in the actual tests. By adding it to the branch "add_sub1", which is the starting point of all other

Sie haben nur Katar Stiftung Spende ** Antwort sofort Sofort **

2017-04-11 Thread QATAR
Sehr geehrter Begünstigter, Ich bin Faith Smith (Frau), der Chief Finance Officer zu unterstützen Sie in Ihrem Anspruchsvorgang. Ich möchte Ihnen gratulieren, dass Sie ein Begünstigter in diesem 2017 Katar Stiftung / Europäische Union (EU) Entschädigungseinheit. Um mit der Verarbeitung zu

Re: What's cooking in git.git (Apr 2017, #01; Tue, 11)

2017-04-11 Thread Jonathan Nieder
Junio C Hamano wrote: > * jk/no-looking-at-dotgit-outside-repo-final (2016-10-26) 1 commit > (merged to 'next' on 2017-02-27 at 7373a1b73d) > + setup_git_env: avoid blind fall-back to ".git" > > This is the endgame of the topic to avoid blindly falling back to > ".git" when the setup

Sie haben nur Katar Stiftung Spende ** Antwort sofort Sofort **

2017-04-11 Thread QATAR
Sehr geehrter Begünstigter, Ich bin Faith Smith (Frau), der Chief Finance Officer zu unterstützen Sie in Ihrem Anspruchsvorgang. Ich möchte Ihnen gratulieren, dass Sie ein Begünstigter in diesem 2017 Katar Stiftung / Europäische Union (EU) Entschädigungseinheit. Um mit der Verarbeitung zu

RE: [PATCH 3/3] reset.c: update files when using sparse to avoid data loss.

2017-04-11 Thread Kevin Willford
> -Original Message- > From: Duy Nguyen [mailto:pclo...@gmail.com] > Sent: Monday, April 10, 2017 4:24 AM > To: Kevin Willford > Cc: git@vger.kernel.org; gits...@pobox.com; p...@peff.net; Kevin Willford > > Subject: Re: [PATCH 3/3] reset.c:

DRÜCKLICHE WARNUNG WARNUNG NOTIFIKATION

2017-04-11 Thread WEBMAIL
Lieber Webmail User, Wegen des überschüssigen aufgegebenen Webmail-Kontos hat sich unser Webmaster entschieden Aktualisieren Sie die Datenbank und löschen Sie inaktive Konten, um Platz zu schaffen Für frische Benutzer. Um Ihr Webmail-Konto zu überprüfen, müssen Sie darauf antworten Diese

Re: [PATCH] fetch-pack: show clearer error message upon ERR

2017-04-11 Thread Jonathan Nieder
Hi, Jonathan Tan wrote: > Currently, fetch-pack prints a confusing error message ("expected > ACK/NAK") when the server it's communicating with sends a pkt-line > starting with "ERR". Replace it with a less confusing error message. Yay! > (Git will send "ERR" lines when a "want" line

Re: Modifying a bare repo directly

2017-04-11 Thread Julian Goacher
Thanks for the replies; is there anything that needs to be known about concurrent updates on a repo when using plumbing commands? On 10 April 2017 at 19:22, Eric Wong wrote: > Julian Goacher wrote: >> Is it possible to modify a bare repo directly? e.g.

Re: [PATCH v4 2/2] p0005-status: time status on very large repo

2017-04-11 Thread Jonathan Nieder
Hi, Jeff Hostetler wrote: > Signed-off-by: Jeff Hostetler Usually the commit message is a place to put some of the motivation behind the patch or why I should want to apply it. In this example, everything is answered by the previous patch,

Re: [PATCH] t6500: don't run detached auto gc at the end of the test script

2017-04-11 Thread Johannes Sixt
Am 10.04.2017 um 19:01 schrieb Jeff King: I wonder if you could make it a general test-lib function, like: run_and_wait () { # we read stdout from the child only for the side effect # of waiting until all child sub-processes exit, closing their # fd 9.

Re: [PATCH v4 1/2] string-list: use ALLOC_GROW macro when reallocing string_list

2017-04-11 Thread Jonathan Nieder
g...@jeffhostetler.com wrote: > During status on a very large repo and there are many changes, > a significant percentage of the total run time is spent > reallocing the wt_status.changes array. > > This change decreases the time in wt_status_collect_changes_worktree() > from 125 seconds to 45

[PATCH] diff: recurse into nested submodules for inline diff

2017-04-11 Thread Stefan Beller
When fd47ae6a5b (diff: teach diff to display submodule difference with an inline diff, 2016-08-31) was introduced, we did not think of recursing into nested submodules. When showing the inline diff for submodules, automatically recurse into nested submodules as well with inline submodule diffs.

Re: [PATCH 01/12] grep: add ability to disable threading with --threads=0 or grep.threads=0

2017-04-11 Thread Ævar Arnfjörð Bjarmason
On Tue, Apr 11, 2017 at 10:34 PM, Jeff King wrote: > On Tue, Apr 11, 2017 at 10:20:59PM +0200, Ævar Arnfjörð Bjarmason wrote: > >> I'm struggling to find a use-case where threading makes sense at all. >> The example in the initial introduction in 5b594f457a is always slower >> with

Re: [PATCH v3 2/2] http: fix the silent ignoring of proxy misconfiguraion

2017-04-11 Thread Sergey Ryazanov
On Tue, Apr 11, 2017 at 8:37 PM, Jeff King wrote: > On Tue, Apr 11, 2017 at 08:17:50PM +0300, Sergey Ryazanov wrote: >> Earlier, the whole http.proxy option string was passed to curl without >> any preprocessing so curl could complain about the invalid proxy >> configuration. >> >>

Re: [PATCH v2] unpack-trees: avoid duplicate ODB lookups during checkout

2017-04-11 Thread Jeff Hostetler
On 4/10/2017 7:09 PM, René Scharfe wrote: Am 10.04.2017 um 23:26 schrieb Jeff Hostetler: On 4/8/2017 10:06 AM, René Scharfe wrote: Am 07.04.2017 um 17:53 schrieb g...@jeffhostetler.com: +/* implicitly borrow buf[i-1] inside tree_desc[i] */ +memcpy([i], [i-1],

Re: `git status` output is very misleading after a merge on a "detached HEAD"

2017-04-11 Thread Ævar Arnfjörð Bjarmason
On Tue, Apr 11, 2017 at 5:13 PM, Enis Bayramoğlu wrote: >> Well, what do you suggest as an alternative? >> >> Git tells you that you are in detached state and where you came from >> (detached from). > > I think it'd be best if git status somehow indicated that you're no >

Re: [PATCH 01/12] grep: add ability to disable threading with --threads=0 or grep.threads=0

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 10:20:59PM +0200, Ævar Arnfjörð Bjarmason wrote: > I'm struggling to find a use-case where threading makes sense at all. > The example in the initial introduction in 5b594f457a is always slower > with >0 for me, and since then in 0579f91dd7 it got disabled entirely > for

[PATCH v4 1/2] http: honor empty http.proxy option to bypass proxy

2017-04-11 Thread Sergey Ryazanov
Curl distinguishes between an empty proxy address and a NULL proxy address. In the first case it completely disables proxy usage, but if the proxy address option is NULL then curl attempts to determine the proxy address from the http_proxy environment variable. According to the documentation, if

[PATCH v4 0/2] http: few fixes for the proxy configuration handling

2017-04-11 Thread Sergey Ryazanov
Hello, this is few patches, which fixes regressions in the proxy handling. Both patches are based on the maint branch. Changes since v3: - fix grammar (thanks to Jeff) Changes since v2: - fix grammar (thanks to Ævar) - add new patch which fixes the silent ignoring of proxy missconfiguration

[PATCH v4 2/2] http: fix the silent ignoring of proxy misconfiguraion

2017-04-11 Thread Sergey Ryazanov
Earlier, the whole http.proxy option string was passed to curl without any preprocessing so curl could complain about the invalid proxy configuration. After the commit 372370f167 ("http: use credential API to handle proxy authentication", 2016-01-26), if the user specified an invalid HTTP proxy

Re: [PATCH 01/12] grep: add ability to disable threading with --threads=0 or grep.threads=0

2017-04-11 Thread Ævar Arnfjörð Bjarmason
On Tue, Apr 11, 2017 at 12:06 PM, Jeff King wrote: > On Sat, Apr 08, 2017 at 01:24:55PM +, Ævar Arnfjörð Bjarmason wrote: > >> Add the ability to entirely disable threading by having grep.threads=0 >> in the config or --threads=0 on the command-line. > > In pack-objects and

Re: [PATCH v4 0/2] string-list: use ALLOC_GROW macro when reallocing

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 08:08:00PM +, g...@jeffhostetler.com wrote: > From: Jeff Hostetler > > Version 4 greatly simplifies the p0005 perf test. It now uses an existing > repo -- either real-world or artificial from t/perf/repos/many-files.sh. > > Jeff Hostetler

[PATCH v4 0/2] string-list: use ALLOC_GROW macro when reallocing

2017-04-11 Thread git
From: Jeff Hostetler Version 4 greatly simplifies the p0005 perf test. It now uses an existing repo -- either real-world or artificial from t/perf/repos/many-files.sh. Jeff Hostetler (2): string-list: use ALLOC_GROW macro when reallocing string_list p0005-status:

[PATCH v4 2/2] p0005-status: time status on very large repo

2017-04-11 Thread git
From: Jeff Hostetler Signed-off-by: Jeff Hostetler --- t/perf/p0005-status.sh | 51 ++ 1 file changed, 51 insertions(+) create mode 100755 t/perf/p0005-status.sh diff --git

[PATCH v4 1/2] string-list: use ALLOC_GROW macro when reallocing string_list

2017-04-11 Thread git
From: Jeff Hostetler Use ALLOC_GROW() macro when reallocing a string_list array rather than simply increasing it by 32. This is a performance optimization. During status on a very large repo and there are many changes, a significant percentage of the total run time is

Re: [PATCH v5 3/8] convert: Split start_multi_file_filter into two separate functions

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 10:01:02PM +0200, Lars Schneider wrote: > > If you initialize errno to 0 right before a syscall, then yes, you can > > trust it without checking the return value of the syscall. I wouldn't > > trust it before calling more complicated functions, though. Not even > >

Re: [PATCH v5 3/8] convert: Split start_multi_file_filter into two separate functions

2017-04-11 Thread Lars Schneider
> On 11 Apr 2017, at 21:37, Jeff King wrote: > > On Tue, Apr 11, 2017 at 09:29:36PM +0200, Lars Schneider wrote: > >>> 1. Do we need to save errno before calling sigchain_pop()? It's making >>>syscalls (though admittedly they are unlikely to fail). >> >> What if we add the

Re: [PATCH v3 4/4] convert: add "status=delayed" to filter process protocol

2017-04-11 Thread Lars Schneider
> On 10 Apr 2017, at 22:54, Torsten Bögershausen wrote: > > On 2017-04-09 21:11, Lars Schneider wrote: > [] >> + >> +packet: git> command=smudge >> +packet: git> pathname=path/testfile.dat >> +packet: git> delay-able=1 >>

[PATCH 1/2] submodule.c: add has_submodules to check if we have any submodules

2017-04-11 Thread Stefan Beller
When submodules are involved, it often slows down the process, as most submodule related handling is either done via a child process or by iterating over the index finding all gitlinks. For most commands that may interact with submodules, we need have a quick check if we do have any submodules at

[PATCH 0/2] clone: record submodule alternates when not recursing

2017-04-11 Thread Stefan Beller
The meat is in the second patch: The commit 31224cbdc7 (clone: recursive and reference option triggers submodule alternates, 2016-08-17) argued for any further `submodule update` to respect the initial setup. This is not the case if you only pass '--reference[-if-able]' to the

[PATCH 2/2] clone: remember references for submodules even when not recursing

2017-04-11 Thread Stefan Beller
The commit 31224cbdc7 (clone: recursive and reference option triggers submodule alternates, 2016-08-17) argued for any further `submodule update` to respect the initial setup. This is not the case if you only pass '--reference[-if-able]' to the initial clone without instructing to recurse into

Re: [PATCH v6] http.postbuffer: allow full range of ssize_t values

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 11:27:40AM -0700, Jonathan Nieder wrote: > David Turner wrote: > > > Unfortunately, in order to push some large repos where a server does > > not support chunked encoding, the http postbuffer must sometimes > > exceed two gigabytes. On a 64-bit system, this is OK: we

Re: [PATCH v5 3/8] convert: Split start_multi_file_filter into two separate functions

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 09:29:36PM +0200, Lars Schneider wrote: > > 1. Do we need to save errno before calling sigchain_pop()? It's making > > syscalls (though admittedly they are unlikely to fail). > > What if we add the following right before sigchain_pop() ? > > if (errno ==

Re: [PATCH v5 3/8] convert: Split start_multi_file_filter into two separate functions

2017-04-11 Thread Lars Schneider
> On 11 Apr 2017, at 18:16, Jeff King wrote: > > On Fri, Apr 07, 2017 at 08:03:49AM -0400, Ben Peart wrote: > >> @@ -642,7 +621,41 @@ static struct cmd2process >> *start_multi_file_filter(struct hashmap *hashmap, cons >> done: >> sigchain_pop(SIGPIPE); >> >> -if (err

Re: [PATCH v9 0/3] read-cache: speed up add_index_entry

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 07:16:59PM +, g...@jeffhostetler.com wrote: > I think this version has addressed everything raise so far, > so I think I'm ready to let this one rest. Thanks for all > the help and feedback. Yeah, this addresses my nitpicks with the perf stuff. Thanks for sticking

[PATCH v9 1/3] read-cache: add strcmp_offset function

2017-04-11 Thread git
From: Jeff Hostetler Add strcmp_offset() function to also return the offset of the first change. Add unit test and helper to verify. Signed-off-by: Jeff Hostetler --- Makefile | 1 + cache.h | 1 +

[PATCH v9 2/3] p0006-read-tree-checkout: perf test to time read-tree

2017-04-11 Thread git
From: Jeff Hostetler Created t/perf/repos/many-files.sh to generate large, but artificial repositories. Created t/perf/p0006-read-tree-checkout.sh to measure performance on various read-tree, checkout, and update-index operations. This test can run using either

[PATCH v9 3/3] read-cache: speed up add_index_entry during checkout

2017-04-11 Thread git
From: Jeff Hostetler Teach add_index_entry_with_check() and has_dir_name() to see if the path of the new item is greater than the last path in the index array before attempting to search for it. During checkout, merge_working_tree() populates the new index in sorted

[PATCH v9 0/3] read-cache: speed up add_index_entry

2017-04-11 Thread git
From: Jeff Hostetler Version 9 addresses the following: () p0006 perf test can now run using either synthetic repos from t/perf/repos/many-repos.sh -OR- an actual real-world repo. () The commit message has been updated to include results of p0006 on

Re: [PATCH 11/12] grep: change the internal PCRE code & header names to be PCRE1

2017-04-11 Thread Ævar Arnfjörð Bjarmason
On Tue, Apr 11, 2017 at 6:51 PM, Brandon Williams wrote: > On 04/11, Jeff King wrote: >> On Tue, Apr 11, 2017 at 01:02:56PM +0200, Ęvar Arnfjörš Bjarmason wrote: >> >> > >> Yes, this is a bug. I'll need to add a git_options along with >> > >> submodule_options and pass -c

Re: [PATCH v6] http.postbuffer: allow full range of ssize_t values

2017-04-11 Thread Jonathan Nieder
David Turner wrote: > Unfortunately, in order to push some large repos where a server does > not support chunked encoding, the http postbuffer must sometimes > exceed two gigabytes. On a 64-bit system, this is OK: we just malloc > a larger buffer. > > This means that we need to use

[PATCH v6] http.postbuffer: allow full range of ssize_t values

2017-04-11 Thread David Turner
Unfortunately, in order to push some large repos where a server does not support chunked encoding, the http postbuffer must sometimes exceed two gigabytes. On a 64-bit system, this is OK: we just malloc a larger buffer. This means that we need to use CURLOPT_POSTFIELDSIZE_LARGE to set the buffer

Re: [PATCH 0/5] forking and threading

2017-04-11 Thread Brandon Williams
On 04/11, Jonathan Nieder wrote: > Brandon Williams wrote: > Jonathan Tan had an idea about how to side-step the issue: what if > "grep" forks an appropriate set of child processes before creating any > threads and then communicates with those children using pipes? > Because no threads have been

Re: [PATCH 5/5] run-command: add note about forking and threading

2017-04-11 Thread Eric Wong
Brandon Williams wrote: > On 04/11, Eric Wong wrote: > > On the other hand, I believe we should make run-command > > vfork-compatible (and Brandon's series is a big (but incomplete) > > step in the (IMHO) right direction); as anything which is > > vfork-safe would also be safe

Re: [PATCH v3 2/2] http: fix the silent ignoring of proxy misconfiguraion

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 08:17:50PM +0300, Sergey Ryazanov wrote: > Earlier, the whole http.proxy option string was passed to curl without > any preprocessing so curl could complain about the invalid proxy > configuration. > > After the commit 372370f167 ("http: use credential API to handle proxy

Re: [PATCH 0/5] forking and threading

2017-04-11 Thread Jonathan Nieder
Brandon Williams wrote: > As far as I understand the only instance of threading and forking which exists > in the current code base is 'git grep --recurse-submodules', and the standard > builds against glibc shouldn't exhibit any of this deadlocking. I don't think we consider builds against

Re: [PATCH 5/5] run-command: add note about forking and threading

2017-04-11 Thread Brandon Williams
On 04/11, Eric Wong wrote: > Jonathan Nieder wrote: > > Why can't git use e.g. posix_spawn to avoid this? > > posix_spawn does not support chdir, and it seems we run non-git > commands so no using "git -C" for those. This is actually the biggest reason why I didn't go down

Re: [PATCH 5/5] run-command: add note about forking and threading

2017-04-11 Thread Jonathan Nieder
Eric Wong wrote: > Jonathan Nieder wrote: >> Why can't git use e.g. posix_spawn to avoid this? > > posix_spawn does not support chdir, and it seems we run non-git > commands so no using "git -C" for those. On the other hand, a number of the non-git commands we run are in a

Re: [PATCH 4/5] run-command: prepare child environment before forking

2017-04-11 Thread Jonathan Nieder
Brandon Williams wrote: > On 04/10, Jonathan Nieder wrote: >> struct argv_array result = ARGV_ARRAY_INIT; >> struct string_list mods = STRING_LIST_INIT_DUP; >> struct strbuf key = STRBUF_INIT; >> const char **p; >> >> for (p = cmd_env; *p; p++) { >> const

Re: [PATCH 4/5] run-command: prepare child environment before forking

2017-04-11 Thread Brandon Williams
On 04/10, Jonathan Nieder wrote: > Brandon Williams wrote: > > > In order to avoid allocation between 'fork()' and 'exec()' prepare the > > environment to be used in the child process prior to forking. > > If using something like posix_spawn(), this would be needed anyway, so > I'll review it. >

[PATCH v3 2/2] http: fix the silent ignoring of proxy misconfiguraion

2017-04-11 Thread Sergey Ryazanov
Earlier, the whole http.proxy option string was passed to curl without any preprocessing so curl could complain about the invalid proxy configuration. After the commit 372370f167 ("http: use credential API to handle proxy authentication", 2016-01-26), if the user specified an invalid HTTP proxy

[PATCH v3 0/2] http: few fixes for the proxy configuration handling

2017-04-11 Thread Sergey Ryazanov
Hello, this is few patches, which fixes regressions in the proxy handling. Changes since v2: - fix grammar (thanks to Ævar) - add new patch which fixes the silent ignoring of proxy missconfiguration Sergey Ryazanov (2): http: honor empty http.proxy option to bypass proxy http: fix the

Re: [PATCH 6/5] run-command: avoid potential dangers in forked child

2017-04-11 Thread Brandon Williams
On 04/11, Eric Wong wrote: > Brandon Williams wrote: > > On 04/11, Eric Wong wrote: > > > Hi Brandon, this series tickles an old itch of mine, so I > > > started working off of it. I'm only somewhat concerned > > > with the path resolution in execvp(e) pontentially calling > >

[PATCH v3 1/2] http: honor empty http.proxy option to bypass proxy

2017-04-11 Thread Sergey Ryazanov
Curl distinguishes between an empty proxy address and a NULL proxy address. In the first case it completely disables proxy usage, but if the proxy address option is NULL then curl attempts to determine the proxy address from the http_proxy environment variable. According to the documentation, if

Re: [PATCH 6/5] run-command: avoid potential dangers in forked child

2017-04-11 Thread Eric Wong
Brandon Williams wrote: > On 04/11, Eric Wong wrote: > > Hi Brandon, this series tickles an old itch of mine, so I > > started working off of it. I'm only somewhat concerned > > with the path resolution in execvp(e) pontentially calling > > malloc on some libcs; but I suppose

Re: [PATCH 11/12] grep: change the internal PCRE code & header names to be PCRE1

2017-04-11 Thread Brandon Williams
On 04/11, Jeff King wrote: > On Tue, Apr 11, 2017 at 01:02:56PM +0200, Ævar Arnfjörð Bjarmason wrote: > > > >> Yes, this is a bug. I'll need to add a git_options along with > > >> submodule_options and pass -c grep.patternType= > > > > > > Maybe that's an indication we should have

Re: [PATCH v3 0/5] propagating push-options, remote and refspec

2017-04-11 Thread Brandon Williams
On 04/11, Junio C Hamano wrote: > Brandon Williams writes: > > > v3 builds upon v2 by adding 3 additional patches to add functionality to > > also > > propagate the remote and refspec down to children process's working to push > > submodules. The remote and refspec will only

Re: [PATCH 6/5] run-command: avoid potential dangers in forked child

2017-04-11 Thread Brandon Williams
On 04/11, Eric Wong wrote: > Hi Brandon, this series tickles an old itch of mine, so I > started working off of it. I'm only somewhat concerned > with the path resolution in execvp(e) pontentially calling > malloc on some libcs; but I suppose that's a separate patch > for another time. > > Only

Re: [PATCH v5 3/8] convert: Split start_multi_file_filter into two separate functions

2017-04-11 Thread Jeff King
On Fri, Apr 07, 2017 at 08:03:49AM -0400, Ben Peart wrote: > @@ -642,7 +621,41 @@ static struct cmd2process > *start_multi_file_filter(struct hashmap *hashmap, cons > done: > sigchain_pop(SIGPIPE); > > - if (err || errno == EPIPE) { > + if (err || errno == EPIPE) > +

git work trees

2017-04-11 Thread taylor, david
We are using Git in a distributed environment. In the United States, we have the master repository in one state and a build cluster in a different state. In addition to people in the US doing builds, we have people in other countries (Ireland, India, Israel, Russia, possibly others) doing

Re: `git status` output is very misleading after a merge on a "detached HEAD"

2017-04-11 Thread Enis Bayramoğlu
> Well, what do you suggest as an alternative? > > Git tells you that you are in detached state and where you came from > (detached from). I think it'd be best if git status somehow indicated that you're no longer at the same commit. Maybe something like: $ git status HEAD detached from

Re: [PATCH v2] http: honnor empty http.proxy option to bypass proxy

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 05:56:56PM +0300, Sergey Ryazanov wrote: > > I don't know _what_ "https://; should do. It's clearly bogus. But > > telling curl to use the defaults seems funny. In that sense, your > > original was much better (we'd feed it to curl, which would be free to > > complain). >

Re: [PATCH v2] http: honnor empty http.proxy option to bypass proxy

2017-04-11 Thread Sergey Ryazanov
On Tue, Apr 11, 2017 at 4:06 PM, Jeff King wrote: > On Tue, Apr 11, 2017 at 12:20:50PM +0300, Sergey Ryazanov wrote: >> diff --git a/http.c b/http.c >> index 96d84bb..8be75b2 100644 >> --- a/http.c >> +++ b/http.c >> @@ -836,8 +836,14 @@ static CURL *get_curl_handle(void) >>

Re: `git status` output is very misleading after a merge on a "detached HEAD"

2017-04-11 Thread Michael J Gruber
Enis Bayramoğlu venit, vidit, dixit 11.04.2017 10:57: > I've encountered a very misleading output from `git status`. Here's a > sequence of events that demonstrates the issue: > > $ git --version > git version 2.12.0 > > $ git checkout origin/master > > $ git status > HEAD detached from

[PATCH v2] Docs: Add some missing options to git-diff.txt

2017-04-11 Thread Andreas Heiduk
New attempt due to whitespace fixes after EndOfSenctence. Junio C Hamano writes: > This is probably a shared issue with the original text for > "diff-files", but I think we must stress that these options make > sense only when you are in the middle of conflict resolution. > > In addition,

Re: [PATCH v2] http: honnor empty http.proxy option to bypass proxy

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 12:20:50PM +0300, Sergey Ryazanov wrote: > diff --git a/http.c b/http.c > index 96d84bb..8be75b2 100644 > --- a/http.c > +++ b/http.c > @@ -836,8 +836,14 @@ static CURL *get_curl_handle(void) > } > } > > - if (curl_http_proxy) { > -

Re: [PATCH 11/12] grep: change the internal PCRE code & header names to be PCRE1

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 01:02:56PM +0200, Ævar Arnfjörð Bjarmason wrote: > >> Yes, this is a bug. I'll need to add a git_options along with > >> submodule_options and pass -c grep.patternType= > > > > Maybe that's an indication we should have --pcre1-regexp and > > --pcre2-regexp, so we don't

Re: [PATCH] read-cache: avoid git_path() race in freshen_shared_index()

2017-04-11 Thread Devan Lucas
Sent from my iPhone

Re: Tools that do an automatic fetch defeat "git push --force-with-lease"

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 02:37:27PM +0200, Stefan Haller wrote: > > I agree that probably makes the multiple-operation stuff go away, which > > is nice. It does raise the question of when the integration point > > happens, and how we handle alternate paths through which commits may > > land in a

Re: Tools that do an automatic fetch defeat "git push --force-with-lease"

2017-04-11 Thread Stefan Haller
Ævar Arnfjör? Bjarmason wrote: > Does this proposal require that all the things that can update a ref > be hooked to maintain these lease values? It is true that the proposal relies on people using git push and git pull, not some lower level approximation such as git fetch +

Re: Tools that do an automatic fetch defeat "git push --force-with-lease"

2017-04-11 Thread Stefan Haller
Jeff King wrote: > On Sun, Apr 09, 2017 at 10:38:42AM +0200, Stefan Haller wrote: > > > I think it's wrong to think about these leases as something that you > > take before you start a rewindy operation. That's the wrong time to take > > the lease; by that time, the remote

Re: Tools that do an automatic fetch defeat "git push --force-with-lease"

2017-04-11 Thread Stefan Haller
Jacob Keller wrote: > On Sun, Apr 9, 2017 at 4:00 AM, Stefan Haller wrote: > > > Maybe I wasn't clear enough about that in my proposal, but I propose to > > always store the commit hash of the remote tracking branch as a new > > lease after push and

Re: [PATCH v5] http.postbuffer: allow full range of ssize_t values

2017-04-11 Thread Lars Schneider
> On 04 Apr 2017, at 17:20, Ramsay Jones wrote: > > > > On 04/04/17 00:53, David Turner wrote: >> Unfortunately, in order to push some large repos, the http postbuffer >> must sometimes exceed two gigabytes. On a 64-bit system, this is OK: >> we just malloc a

Re: [PATCH] connect.c: handle errors from split_cmdline

2017-04-11 Thread Ævar Arnfjörð Bjarmason
On Tue, Apr 11, 2017 at 12:54 PM, Jeff King wrote: > On Tue, Apr 11, 2017 at 11:27:57AM +0200, Ævar Arnfjörð Bjarmason wrote: > >> Junio: If you're not in some rush to pick this up I'll take this, fix >> up a bunch of other bugs & tests failures on odd --root directories >> and

Re: [PATCH 11/12] grep: change the internal PCRE code & header names to be PCRE1

2017-04-11 Thread Ævar Arnfjörð Bjarmason
On Tue, Apr 11, 2017 at 12:48 PM, Jeff King wrote: > On Tue, Apr 11, 2017 at 12:45:55PM +0200, Ævar Arnfjörð Bjarmason wrote: > >> On Tue, Apr 11, 2017 at 12:37 PM, Jeff King wrote: >> > On Sat, Apr 08, 2017 at 01:25:05PM +, Ævar Arnfjörð Bjarmason wrote: >> >

Re: [PATCH] connect.c: handle errors from split_cmdline

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 11:27:57AM +0200, Ævar Arnfjörð Bjarmason wrote: > Junio: If you're not in some rush to pick this up I'll take this, fix > up a bunch of other bugs & tests failures on odd --root directories > and submit this and Jeff's \r patch (after adding tests etc) along > with it.

Re: [PATCH 10/12] grep: change the internal PCRE macro names to be PCRE1

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 12:51:09PM +0200, Ævar Arnfjörð Bjarmason wrote: > > Yeah, I think it's nice to keep the build-time knobs compatible. In the > > long run I assume we'll want to add a USE_LIBPCRE1 flag and USE_LIBPCRE > > just becomes a synonym for it (in fact, we could do that in this > >

Re: [PATCH 10/12] grep: change the internal PCRE macro names to be PCRE1

2017-04-11 Thread Ævar Arnfjörð Bjarmason
On Tue, Apr 11, 2017 at 12:35 PM, Jeff King wrote: > On Sat, Apr 08, 2017 at 01:25:04PM +, Ævar Arnfjörð Bjarmason wrote: > >> Change the internal USE_LIBPCRE define, & build options flag to use a >> naming convention ending in PCRE1, without changing the long-standing >>

Re: [PATCH 05/12] log: add exhaustive tests for pattern style options & config

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 12:32:57PM +0200, Ævar Arnfjörð Bjarmason wrote: > > This can be tricky since POSIX allows implementations to add arbitrary > > extensions for otherwise invalid syntax. > > For POSIX basic v.s. extended I'm relying on (|) not being > metacharacters in basic but metachars

Re: [PATCH 11/12] grep: change the internal PCRE code & header names to be PCRE1

2017-04-11 Thread Jeff King
On Tue, Apr 11, 2017 at 12:45:55PM +0200, Ævar Arnfjörð Bjarmason wrote: > On Tue, Apr 11, 2017 at 12:37 PM, Jeff King wrote: > > On Sat, Apr 08, 2017 at 01:25:05PM +, Ævar Arnfjörð Bjarmason wrote: > > > >> diff --git a/builtin/grep.c b/builtin/grep.c > >> index

Re: [PATCH 00/12] PCREv2 & more

2017-04-11 Thread Jeff King
On Sat, Apr 08, 2017 at 01:24:54PM +, Ævar Arnfjörð Bjarmason wrote: > This adds PCRE v2 support, but as I was adding that I kept noticing > other related problems to fix. It's all bundled up into the same > series because much of it conflicts because it modifies the same test > or other

Re: [PATCH 12/12] grep: add support for PCRE v2

2017-04-11 Thread Jeff King
On Sat, Apr 08, 2017 at 01:25:06PM +, Ævar Arnfjörð Bjarmason wrote: > --- a/Makefile > +++ b/Makefile > @@ -32,6 +32,14 @@ all:: > # Define LIBPCREDIR=/foo/bar if your libpcre header and library files are in > # /foo/bar/include and /foo/bar/lib directories. > # > +# Define USE_LIBPCRE if

Re: [PATCH 11/12] grep: change the internal PCRE code & header names to be PCRE1

2017-04-11 Thread Ævar Arnfjörð Bjarmason
On Tue, Apr 11, 2017 at 12:37 PM, Jeff King wrote: > On Sat, Apr 08, 2017 at 01:25:05PM +, Ævar Arnfjörð Bjarmason wrote: > >> diff --git a/builtin/grep.c b/builtin/grep.c >> index 9478ab5dff..dffb9743b8 100644 >> --- a/builtin/grep.c >> +++ b/builtin/grep.c >> @@ -490,7 +490,7

Re: [PATCH 11/12] grep: change the internal PCRE code & header names to be PCRE1

2017-04-11 Thread Jeff King
On Sat, Apr 08, 2017 at 01:25:05PM +, Ævar Arnfjörð Bjarmason wrote: > diff --git a/builtin/grep.c b/builtin/grep.c > index 9478ab5dff..dffb9743b8 100644 > --- a/builtin/grep.c > +++ b/builtin/grep.c > @@ -490,7 +490,7 @@ static void compile_submodule_options(const struct > grep_opt *opt, >

Re: [PATCH 10/12] grep: change the internal PCRE macro names to be PCRE1

2017-04-11 Thread Jeff King
On Sat, Apr 08, 2017 at 01:25:04PM +, Ævar Arnfjörð Bjarmason wrote: > Change the internal USE_LIBPCRE define, & build options flag to use a > naming convention ending in PCRE1, without changing the long-standing > USE_LIBPCRE Makefile flag which enables this code. > > This is for

Re: [PATCH 05/12] log: add exhaustive tests for pattern style options & config

2017-04-11 Thread Ævar Arnfjörð Bjarmason
On Tue, Apr 11, 2017 at 12:23 PM, Jeff King wrote: > On Sat, Apr 08, 2017 at 01:24:59PM +, Ævar Arnfjörð Bjarmason wrote: > >> Add exhaustive tests for how the different grep.patternType options & >> the corresponding command-line options affect git-log. >> >> Before this

Re: [PATCH 09/12] test-lib: rename the LIBPCRE prerequisite to PCRE

2017-04-11 Thread Jeff King
On Sat, Apr 08, 2017 at 01:25:03PM +, Ævar Arnfjörð Bjarmason wrote: > Rename the LIBPCRE prerequisite to PCRE. This is for preparation for > libpcre2 support, where having just "LIBPCRE" would be confusing as it > implies v1 of the library. > > None of these tests are incompatible between

  1   2   >