Re: [PATCH] http: fix v1 protocol tests with apache httpd < 2.4

2018-01-02 Thread Jeff King
On Tue, Jan 02, 2018 at 07:39:46PM -0500, Todd Zullinger wrote: > Brandon Williams wrote: > > Seems good to me. I think I was just being overly cautious when i was > > implementing those patches. Thanks! > > Cool, thanks for taking a look. > > In this case, the test isn't dependent on apache

Re: [PATCH] http: fix v1 protocol tests with apache httpd < 2.4

2018-01-02 Thread Jeff King
On Sat, Dec 30, 2017 at 09:32:34PM -0500, Todd Zullinger wrote: > The apache config used by tests was updated to use the SetEnvIf > directive to set the Git-Protocol header in 19113a26b6 ("http: tell > server that the client understands v1", 2017-10-16). > > Setting the Git-Protocol header is

Re: [ANNOUNCE] Git v2.16.0-rc0

2018-01-02 Thread Jonathan Nieder
Bryan Turner wrote: > On Tue, Jan 2, 2018 at 9:07 PM, Jonathan Nieder wrote: >> So my first question is why the basename detection is not working for >> you. What value of GIT_SSH, GIT_SSH_COMMAND, or core.sshCommand are >> you using? > > So I'd been digging further into

Re: [ANNOUNCE] Git v2.16.0-rc0

2018-01-02 Thread Bryan Turner
On Tue, Jan 2, 2018 at 9:07 PM, Jonathan Nieder wrote: > Hi Bryan, > > Bryan Turner wrote: > >> Our test environment is still on Ubuntu 12.04 LTS (it's a long story, >> but one I doubt is unique to us), which means it's using OpenSSH 5.9. >> ssh -G was added in OpenSSH 6.8

Re: [ANNOUNCE] Git v2.16.0-rc0

2018-01-02 Thread Jonathan Nieder
Hi, A few more notes. Bryan Turner wrote: > bturner@ubuntu:~$ ssh -V > OpenSSH_6.6.1p1 Ubuntu-2ubuntu2.8, OpenSSL 1.0.1f 6 Jan 2014 > > bturner@ubuntu:~$ ssh -G -p 7999 localhost > unknown option -- G > usage: ssh [-1246AaCfgKkMNnqsTtVvXxYy] [-b bind_address] [-c cipher_spec] [...] > Is it

Re: [ANNOUNCE] Git v2.16.0-rc0

2018-01-02 Thread Jonathan Nieder
Hi Bryan, Bryan Turner wrote: > Our test environment is still on Ubuntu 12.04 LTS (it's a long story, > but one I doubt is unique to us), which means it's using OpenSSH 5.9. > ssh -G was added in OpenSSH 6.8 [1], circa March 2015, which means the > "auto" detection "fails" and chooses "simple"

Re: [PATCH v5 04/34] directory rename detection: basic testcases

2018-01-02 Thread Elijah Newren
On Tue, Jan 2, 2018 at 5:18 PM, SZEDER Gábor wrote: > >> --- >> t/t6043-merge-rename-directories.sh | 430 >> > > Many of the new tests added in this patch series perform a lot of checks > running 'test', which has the drawback to fail

Re: [ANNOUNCE] Git v2.16.0-rc0

2018-01-02 Thread Bryan Turner
On Thu, Dec 28, 2017 at 8:30 PM, Junio C Hamano wrote: > An early preview release Git v2.16.0-rc0 is now available for > testing at the usual places. It is comprised of 435 non-merge > commits since v2.15.0, contributed by 76 people, 22 of which are > new faces. > Brandon

Re: [PATCH v5 04/34] directory rename detection: basic testcases

2018-01-02 Thread SZEDER Gábor
> --- > t/t6043-merge-rename-directories.sh | 430 > Many of the new tests added in this patch series perform a lot of checks running 'test', which has the drawback to fail quietly, leaving us no clue about which one of the several conditions failed and why.

[PATCH 1/5] t/helper/test-lazy-name-hash: fix compilation

2018-01-02 Thread Stefan Beller
I was compiling origin/master today with stricter compiler flags today and was greeted by t/helper/test-lazy-init-name-hash.c: In function ‘cmd_main’: t/helper/test-lazy-init-name-hash.c:172:5: error: ‘nr_threads_used’ may be used uninitialized in this function [-Werror=maybe-uninitialized]

[PATCH 5/5] submodule: submodule_move_head omits old argument in forced case

2018-01-02 Thread Stefan Beller
When using hard reset or forced checkout with the option to recurse into submodules, the submodules need to be reset, too. It turns out that we need to omit the duplicate old argument to read-tree in all forced cases to omit the 2 way merge and use the more assertive behavior of reading the

[PATCH 4/5] unpack-trees: oneway_merge to update submodules

2018-01-02 Thread Stefan Beller
When there is a one way merge, each submodule needs to be one way merged as well, if we're asked to recurse into submodules. In case of a submodule, check if it is up-to-date, otherwise set the flag CE_UPDATE, which will trigger an update of it in the phase updating the tree later.

[PATCH 2/5] t/lib-submodule-update.sh: clarify test

2018-01-02 Thread Stefan Beller
Keep the local branch name as the upstream branch name to avoid confusion. Signed-off-by: Stefan Beller --- t/lib-submodule-update.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/t/lib-submodule-update.sh b/t/lib-submodule-update.sh index

[PATCH 3/5] t/lib-submodule-update.sh: Fix test ignoring ignored files in submodules

2018-01-02 Thread Stefan Beller
It turns out that the test replacing a submodule with a file with the submodule containing an ignored file is incorrectly titled, because the test put the file in place, but never ignored that file. When having an untracked file Instead of an ignored file in the submodule, git should refuse to

[PATCHv3 0/5] Fix --recurse-submodules for submodule worktree changes

2018-01-02 Thread Stefan Beller
Thanks Junio for review of this series! The only change in this version of the series is --- a/unpack-trees.c +++ b/unpack-trees.c @@ -2140,7 +2140,7 @@ int oneway_merge(const struct cache_entry * const *src, update |= CE_UPDATE; }

Re: [PATCH 5/5] diff: properly error out when combining multiple pickaxe options

2018-01-02 Thread Jacob Keller
On Tue, Jan 2, 2018 at 4:46 PM, Stefan Beller wrote: > die(_("--name-only, --name-status, --check and -s are > mutually exclusive")); > + count = 0; > + > + if (options->pickaxe_opts & DIFF_PICKAXE_KIND_S) > + count++; > + if

[PATCHv2 4/5] diffcore: add a pickaxe option to find a specific blob

2018-01-02 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

[PATCH 4/5] diffcore: add a pickaxe option to find a specific blob

2018-01-02 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

[PATCH 2/5] diff: migrate diff_flags.pickaxe_ignore_case to a pickaxe_opts bit

2018-01-02 Thread Stefan Beller
Currently flags for pickaxing are found in different places. Unify the flags into the `pickaxe_opts` field, which will contain any pickaxe related flags. Signed-off-by: Stefan Beller --- diff.h | 3 ++- diffcore-pickaxe.c | 6 +++--- revision.c | 2 +- 3

[PATCH 3/5] diff: introduce DIFF_PICKAXE_KINDS_MASK

2018-01-02 Thread Stefan Beller
Currently the check whether to perform pickaxing is done via checking `diffopt->pickaxe`, which contains the command line argument that we want to pickaxe for. Soon we'll introduce a new type of pickaxing, that will not store anything in the `.pickaxe` field, so let's migrate the check to be

[PATCH 5/5] diff: properly error out when combining multiple pickaxe options

2018-01-02 Thread Stefan Beller
In f506b8e8b5 (git log/diff: add -G that greps in the patch text, 2010-08-23) we were hesitant to check if the user requests both -S and -G at the same time. Now that the pickaxe family also offers --find-object, which looks slightly more different than the former two, let's add a check that those

[PATCH 1/5] diff.h: Make pickaxe_opts an unsigned bit field

2018-01-02 Thread Stefan Beller
This variable is used as a bit field[1], and as we are about to add more fields, indicate its usage as a bit field by making it unsigned. [1] containing the bits #define DIFF_PICKAXE_ALL1 #define DIFF_PICKAXE_REGEX 2 #define DIFF_PICKAXE_KIND_S 4 #define DIFF_PICKAXE_KIND_G

[PATCH 0/5] pickaxe refactorings and a new mode to find blobs (WAS: diffcore: add a pickaxe option to find a specific blob)

2018-01-02 Thread Stefan Beller
After some discussion [1], we're convinced that the original approach for adding in just another pickaxe mode to find blobs was too hacky. So I went the less hacky way and did some refactoring first (patches 1-3), Then we'll have the new pickaxe mode to find blobs in patch 4. It grew slightly

Re: [PATCH] http: fix v1 protocol tests with apache httpd < 2.4

2018-01-02 Thread Todd Zullinger
Brandon Williams wrote: > Seems good to me. I think I was just being overly cautious when i was > implementing those patches. Thanks! Cool, thanks for taking a look. In this case, the test isn't dependent on apache > 2.4, but before I checked that I wondered if we had any way to run a test

Re: [PATCH] http: fix v1 protocol tests with apache httpd < 2.4

2018-01-02 Thread Brandon Williams
On 12/30, Todd Zullinger wrote: > The apache config used by tests was updated to use the SetEnvIf > directive to set the Git-Protocol header in 19113a26b6 ("http: tell > server that the client understands v1", 2017-10-16). > > Setting the Git-Protocol header is restricted to httpd >= 2.4, but >

[PATCH 10/26] protocol: introduce enum protocol_version value protocol_v2

2018-01-02 Thread Brandon Williams
Introduce protocol_v2, a new value for 'enum protocol_version'. Subsequent patches will fill in the implementation of protocol_v2. Signed-off-by: Brandon Williams --- builtin/fetch-pack.c | 3 +++ builtin/receive-pack.c | 6 ++ builtin/send-pack.c| 3 +++ connect.c

[PATCH 06/26] transport: use get_refs_via_connect to get refs

2018-01-02 Thread Brandon Williams
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 --- transport.c | 18 -- 1 file changed, 4 insertions(+), 14

[PATCH 09/26] transport: store protocol version

2018-01-02 Thread Brandon Williams
Once protocol_v2 is introduced requesting a fetch or a push will need to be handled differently depending on the protocol version. Store the protocol version the server is speaking in 'struct git_transport_data' and use it to determine what to do in the case of a fetch or a push. Signed-off-by:

[PATCH 11/26] serve: introduce git-serve

2018-01-02 Thread Brandon Williams
Introduce git-serve, the base server for protocol version 2. Protocol version 2 is intended to be a replacement for Git's current wire protocol. The intention is that it will be a simpler, less wasteful protocol which can evolve over time. Protocol version 2 improves upon version 1 by

[PATCH 17/26] fetch: pass ref patterns when fetching

2018-01-02 Thread Brandon Williams
Construct a list of ref patterns to be passed to 'transport_get_remote_refs()' from the refspec to be used during the fetch. This list of ref patterns will be used to allow the server to filter the ref advertisement when communicating using protocol v2. Signed-off-by: Brandon Williams

[PATCH 15/26] transport: convert transport_get_remote_refs to take a list of ref patterns

2018-01-02 Thread Brandon Williams
Convert 'transport_get_remote_refs()' to optionally take a list of ref patterns. Signed-off-by: Brandon Williams --- builtin/clone.c | 2 +- builtin/fetch.c | 4 ++-- builtin/ls-remote.c | 2 +- builtin/remote.c| 2 +- transport.c | 7 +-- transport.h

[PATCH 22/26] transport-helper: refactor process_connect_service

2018-01-02 Thread Brandon Williams
A future patch will need to take advantage of the logic which runs and processes the response of the connect command on a remote helper so factor out this logic from 'process_connect_service()' and place it into a helper function 'run_connect()'. Signed-off-by: Brandon Williams

[PATCH 25/26] remote-curl: create copy of the service name

2018-01-02 Thread Brandon Williams
Make a copy of the service name being requested instead of relying on the buffer pointed to by the passed in 'const char *' to remain unchanged. Signed-off-by: Brandon Williams --- remote-curl.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git

[PATCH 19/26] upload-pack: introduce fetch server command

2018-01-02 Thread Brandon Williams
Introduce the 'fetch' server command. Signed-off-by: Brandon Williams --- Documentation/technical/protocol-v2.txt | 14 ++ serve.c | 2 + upload-pack.c | 290 upload-pack.h

[PATCH 12/26] ls-refs: introduce ls-refs server command

2018-01-02 Thread Brandon Williams
Introduce the ls-refs server command. In protocol v2, the ls-refs command is used to request the ref advertisement from the server. Since it is a command which can be requested (as opposed to mandatory in v1), a client can sent a number of parameters in its request to limit the ref advertisement

[PATCH 26/26] remote-curl: implement connect-half-duplex command

2018-01-02 Thread Brandon Williams
Teach remote-curl the 'connect-half-duplex' command which is used to establish a half-duplex connection with servers which support protocol version 2. This allows remote-curl to act as a proxy, allowing the git client to communicate natively with a remote end, simply using remote-curl as a pass

[PATCH 24/26] pkt-line: add packet_buf_write_len function

2018-01-02 Thread Brandon Williams
Add the 'packet_buf_write_len()' function which allows for writing an arbitrary length buffer into a 'struct strbuf' and formatting it in packet-line format. Signed-off-by: Brandon Williams --- pkt-line.c | 16 pkt-line.h | 1 + 2 files changed, 17

[PATCH 23/26] transport-helper: introduce connect-half-duplex

2018-01-02 Thread Brandon Williams
Introduce the transport-helper capability 'connect-half-duplex'. This capability indicates that the transport-helper can be requested to run the 'connect-half-duplex' command which should attempt to make a half-duplex connection with a remote end. Once established, the half-duplex connection can

[PATCH 20/26] fetch-pack: perform a fetch using v2

2018-01-02 Thread Brandon Williams
When communicating with a v2 server, perform a fetch by requesting the 'fetch' command. Signed-off-by: Brandon Williams --- builtin/fetch-pack.c | 2 +- fetch-pack.c | 267 - fetch-pack.h | 4 +-

[PATCH 21/26] transport-helper: remove name parameter

2018-01-02 Thread Brandon Williams
Commit 266f1fdfa (transport-helper: be quiet on read errors from helpers, 2013-06-21) removed a call to 'die()' which printed the name of the remote helper passed in to the 'recvline_fh()' function using the 'name' parameter. Once the call to 'die()' was removed the parameter was no longer

[PATCH 05/26] upload-pack: factor out processing lines

2018-01-02 Thread Brandon Williams
Factor out the logic for processing shallow, deepen, deepen_since, and deepen_not lines into their own functions to simplify the 'receive_needs()' function in addition to making it easier to reuse some of this logic when implementing protocol_v2. Signed-off-by: Brandon Williams

[PATCH 03/26] pkt-line: add delim packet support

2018-01-02 Thread Brandon Williams
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 one side has finished speaking. This makes it particularly difficult to implement

[PATCH 18/26] push: pass ref patterns when pushing

2018-01-02 Thread Brandon Williams
Construct a list of ref patterns to be passed to 'get_refs_list()' from the refspec to be used during the push. This list of ref patterns will be used to allow the server to filter the ref advertisement when communicating using protocol v2. Signed-off-by: Brandon Williams ---

[PATCH 00/26] protocol version 2

2018-01-02 Thread Brandon Williams
The following patches extend what I sent out as an WIP (https://public-inbox.org/git/20171204235823.63299-1-bmw...@google.com/) and implement protocol version 2. Some changes from that series are as follows: * Lots of various cleanup on the ls-refs and fetch command code, both server and

[PATCH 16/26] ls-remote: pass ref patterns when requesting a remote's refs

2018-01-02 Thread Brandon Williams
Construct an argv_array of the ref patterns supplied via the command line and pass them to 'transport_get_remote_refs()' to be used when communicating protocol v2 so that the server can limit the ref advertisement based on the supplied patterns. Signed-off-by: Brandon Williams

[PATCH 14/26] transport: convert get_refs_list to take a list of ref patterns

2018-01-02 Thread Brandon Williams
Convert the 'struct transport' virtual function 'get_refs_list()' to optionally take an argv_array of ref patterns. When communicating with a server using protocol v2 these ref patterns can be sent when requesting a listing of their refs allowing the server to filter the refs it sends based on

[PATCH 04/26] upload-pack: convert to a builtin

2018-01-02 Thread Brandon Williams
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 --- Makefile | 3 ++- builtin.h | 1 + git.c | 1 + upload-pack.c | 2 +- 4 files changed, 5 insertions(+), 2

[PATCH 07/26] connect: convert get_remote_heads to use struct packet_reader

2018-01-02 Thread Brandon Williams
In order to allow for better control flow when protocol_v2 is introduced convert 'get_remote_heads()' to use 'struct packet_reader' to read packet lines. This enables a client to be able to peek the first line of a server's response (without consuming it) in order to determine the protocol

[PATCH 01/26] pkt-line: introduce packet_read_with_status

2018-01-02 Thread Brandon Williams
The current pkt-line API encodes the status of a pkt-line read in the length of the read content. An error is indicated with '-1', a flush with '0' (which can be confusing since a return value of '0' can also indicate an empty pkt-line), and a positive integer for the length of the read content

[PATCH 13/26] connect: request remote refs using v2

2018-01-02 Thread Brandon Williams
Teach the client to be able to request a remote's refs using protocol v2. This is done by having a client issue a 'ls-refs' request to a v2 server. Signed-off-by: Brandon Williams --- connect.c | 101 - remote.h

[PATCH 08/26] connect: discover protocol version outside of get_remote_heads

2018-01-02 Thread Brandon Williams
In order to prepare for the addition of protocol_v2 push the protocol version discovery outside of 'get_remote_heads()'. This will allow for keeping the logic for processing the reference advertisement for protocol_v1 and protocol_v0 separate from the logic for protocol_v2. Signed-off-by:

[PATCH 02/26] pkt-line: introduce struct packet_reader

2018-01-02 Thread Brandon Williams
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 packet_reader' which is an abstraction around the normal packet reading logic. This enables a

Re: [PATCH v5 00/34] Add directory rename detection to git

2018-01-02 Thread Elijah Newren
On Wed, Dec 27, 2017 at 8:13 PM, Elijah Newren wrote: > This patchset introduces directory rename detection to merge-recursive. See > https://public-inbox.org/git/20171110190550.27059-1-new...@gmail.com/ > for the first series (including design considerations, etc.), and

Re: [PATCH 4/4] clone: do not clean up directories we didn't create

2018-01-02 Thread Jeff King
On Tue, Jan 02, 2018 at 05:49:45PM -0500, Eric Sunshine wrote: > > diff --git a/t/t5600-clone-fail-cleanup.sh b/t/t5600-clone-fail-cleanup.sh > > @@ -42,13 +53,48 @@ test_expect_success 'successful clone must leave the > > directory' ' > > +test_expect_success 'failed clone into empty leaves

Re: [PATCH 2/2] travis-ci: check that all build artifacts are .gitignore-d

2018-01-02 Thread SZEDER Gábor
On Tue, Jan 2, 2018 at 8:40 PM, Lars Schneider wrote: > >> On 31 Dec 2017, at 17:02, SZEDER Gábor wrote: >> >> Every once in a while our explicit .gitignore files get out of sync >> when our build process learns to create new artifacts, like test

RE: [Bug] NO_INTPTR_T not being honoured in compat/regex/regcomp.c

2018-01-02 Thread Randall S. Becker
On January 1, 2018 4:51 PM Eric Sunshine wrote: > On Mon, Jan 1, 2018 at 4:21 PM, Randall S. Becker > wrote: > > * I have defined NO_INTPTR_T = UnfortunatelyYes in config.mak.uname > > for my platform. The c99 compiler I have does not define it. > > * The code compiles

Re: [PATCHv2 4/5] unpack-trees: oneway_merge to update submodules

2018-01-02 Thread Stefan Beller
On Tue, Jan 2, 2018 at 11:43 AM, Junio C Hamano wrote: > Stefan Beller writes: > >> diff --git a/unpack-trees.c b/unpack-trees.c >> index bf8b602901..ac59524a7f 100644 >> --- a/unpack-trees.c >> +++ b/unpack-trees.c >> @@ -2139,6 +2139,9 @@ int

Re: [PATCH 4/4] clone: do not clean up directories we didn't create

2018-01-02 Thread Eric Sunshine
On Tue, Jan 2, 2018 at 4:11 PM, Jeff King wrote: > [...] > Because we know that the only directory we'll write into is > an empty one, we can handle this case by just passing the > KEEP_TOPLEVEL flag to our recursive delete (if we could > write into populated directories, we'd have

Re: What's cooking in git.git (Dec 2017, #05; Wed, 27)

2018-01-02 Thread Jonathan Nieder
Stefan Beller wrote: > On Thu, Dec 28, 2017 at 11:02 AM, Junio C Hamano wrote: >> Elijah Newren writes: >>> surprised by the branch name, though. Was 'ew/' a typo, >> >> Blush X-<. Yes it is a typo. > > Note on that series: > I have reviewed the first

Re: [PATCH v2 1/5] core.aheadbehind: add new config setting

2018-01-02 Thread Jonathan Nieder
Hi, Jeff Hostetler wrote: > On 12/21/2017 3:43 PM, Jonathan Nieder wrote: >> I also wonder if there's a way to achieve the same benefit without >> having it be configurable. E.g. if a branch is way behind, couldn't >> we terminate the walk early to get the same bounded cost per branch >>

Re: [PATCH v2 1/5] core.aheadbehind: add new config setting

2018-01-02 Thread Jeff Hostetler
On 12/21/2017 3:43 PM, Jonathan Nieder wrote: Hi, Jeff Hostetler wrote: Created core.aheadbehind config setting and core_ahead_behind global variable. This value defaults to true. This value will be used in the next few commits as the default value for the --ahead-behind parameter.

Re: [PATCH] git-archive: accept --owner and --group like GNU tar

2018-01-02 Thread René Scharfe
Am 02.01.2018 um 07:58 schrieb suzuki toshiya: > Dear René , > > René Scharfe wrote: >> Am 29.12.2017 um 15:05 schrieb suzuki toshiya: >>> The ownership of files created by git-archive is always >>> root:root. Add --owner and --group options which work >>> like the GNU tar equivalent to allow

Re: [PATCH v3 0/6] Renames in git-status "changed not staged" section

2018-01-02 Thread Jeff Hostetler
On 12/27/2017 5:18 AM, Nguyễn Thái Ngọc Duy wrote: v3 more or less goes back to v1 after my discussion with Igor about porcelain formats. So 7/7 is not needed anymore. 4/7 becomes 5/6. The meat is still in 6/6, now with some more updates in git-status.txt and to address the comment from

Re: [PATCH] status: handle worktree renames

2018-01-02 Thread Jeff Hostetler
On 12/27/2017 1:12 PM, Junio C Hamano wrote: Duy Nguyen writes: Or we disable rename-from-worktree when porcelain v2 is requested (and optionally introduce v3 to support it). Jeff, any preference? Sorry for the delay, I was on vacation last week. I like the "R." and

[PATCH 4/4] clone: do not clean up directories we didn't create

2018-01-02 Thread Jeff King
Once upon a time, git-clone would refuse to write into a directory that it did not itself create. The cleanup routines for a failed clone could therefore just remove the git and worktree dirs completely. In 55892d2398 (Allow cloning to an existing empty directory, 2009-01-11), we learned to write

[PATCH 3/4] clone: factor out dir_exists() helper

2018-01-02 Thread Jeff King
Two parts of git-clone's setup logic check whether a directory exists, and they both call stat directly with the same scratch "struct stat" buffer. Let's pull that into a helper, which has a few advantages: - it makes the purpose of the stat calls more obvious - it makes it clear that we

[PATCH 2/4] t5600: modernize style

2018-01-02 Thread Jeff King
This is an old script which could use some updating before we add to it: - use the standard line-breaking: test_expect_success 'title' ' body ' - run all code inside test_expect blocks to catch unexpected failures in setup steps - use "test_commit -C"

[PATCH 1/4] t5600: fix outdated comment about unborn HEAD

2018-01-02 Thread Jeff King
Back when this test was written, git-clone could not handle a repository without any commits. These days it works fine, and this comment is out of date. At first glance it seems like we could just drop this code entirely now, but it's necessary for the final test, which was added later. That test

[PATCH 0/4] Git removes existing folder when cancelling clone

2018-01-02 Thread Jeff King
On Tue, Jan 02, 2018 at 03:04:43PM -0500, Jeff King wrote: > So I don't think there's an urgent data-loss bug here; we will only ever > destroy an empty directory. However, the original intent was to leave > the filesystem as we found it on a failed or aborted clone, and we > obviously don't do

Re: [PATCH ab/simplify-perl-makefile] perl: treat PERLLIB_EXTRA as an extra path again (Re: [PATCH v6] Makefile: replace perl/Makefile.PL with simple make rules)

2018-01-02 Thread Ævar Arnfjörð Bjarmason
On Tue, Jan 02 2018, Jonathan Nieder jotted: > Subject: perl: treat PERLLIB_EXTRA as an extra path again > > PERLLIB_EXTRA was introduced in v1.9-rc0~88^2 (2013-11-15) as a way > for packagers to add additional directories such as the location of > Subversion's perl bindings to Git's perl path.

Re: Git removes existing folder when cancelling clone

2018-01-02 Thread Jeff King
On Tue, Jan 02, 2018 at 06:12:35AM -0500, Robert P. J. Day wrote: > > I just noticed the following behaviour on macOS 10.13.2 running Git v2.15.0: > > > > 1. `mkdir new-folder` > > 2. `ls` - shows new-folder > > 3. `git clone [repo] new-folder` > > 4. Git asks for password > > 5. I cancel by

Re: What's cooking in git.git (Dec 2017, #05; Wed, 27)

2018-01-02 Thread Stefan Beller
On Thu, Dec 28, 2017 at 11:02 AM, Junio C Hamano wrote: > Elijah Newren writes: > >> surprised by the branch name, though. Was 'ew/' a typo, > > Blush X-<. Yes it is a typo. Note on that series: I have reviewed the first three patches (which could form an

[PATCH ab/simplify-perl-makefile] perl: treat PERLLIB_EXTRA as an extra path again (Re: [PATCH v6] Makefile: replace perl/Makefile.PL with simple make rules)

2018-01-02 Thread Jonathan Nieder
Subject: perl: treat PERLLIB_EXTRA as an extra path again PERLLIB_EXTRA was introduced in v1.9-rc0~88^2 (2013-11-15) as a way for packagers to add additional directories such as the location of Subversion's perl bindings to Git's perl path. Since 20d2a30f (Makefile: replace perl/Makefile.PL with

Re: [PATCHv2 4/5] unpack-trees: oneway_merge to update submodules

2018-01-02 Thread Junio C Hamano
Stefan Beller writes: > diff --git a/unpack-trees.c b/unpack-trees.c > index bf8b602901..ac59524a7f 100644 > --- a/unpack-trees.c > +++ b/unpack-trees.c > @@ -2139,6 +2139,9 @@ int oneway_merge(const struct cache_entry * const *src, >

Re: [PATCH 2/2] travis-ci: check that all build artifacts are .gitignore-d

2018-01-02 Thread Lars Schneider
> On 31 Dec 2017, at 17:02, SZEDER Gábor wrote: > > Every once in a while our explicit .gitignore files get out of sync > when our build process learns to create new artifacts, like test > helper executables, but the .gitignore files are not updated > accordingly. > > Use

Re: [PATCH 1/2] travis-ci: don't store P4 and Git LFS in the working tree

2018-01-02 Thread Lars Schneider
> On 31 Dec 2017, at 17:02, SZEDER Gábor wrote: > > The Clang and GCC 64 bit Linux build jobs download and store the P4 > and Git LFS executables under the current directory, which is the > working tree that we are about to build and test. This means that Git > commands

Re: Test failure for v2.16.0-rc0 on cygwin

2018-01-02 Thread Ramsay Jones
On 02/01/18 15:32, Ramsay Jones wrote: > On 02/01/18 11:36, Adam Dinwoodie wrote: >> On Saturday 30 December 2017 at 02:40 pm +, Adam Dinwoodie wrote: >>> On Saturday 30 December 2017 at 02:21 pm +, Ramsay Jones wrote: [snip] >> I'm not able to reproduce this: t5580 is passing on both my

Re: [PATCH 4/4] branch: add '--show-description' option

2018-01-02 Thread SZEDER Gábor
On Tue, Jan 2, 2018 at 10:32 AM, Johannes Sixt wrote: > > Which makes me wonder: Why would --show-description have to error out > > silently? This is not 'git config' after all. > I don't have a strong opinion about this, and certainly wouldn't mind > adding an error message

Re: [PATCH v6] Makefile: replace perl/Makefile.PL with simple make rules

2018-01-02 Thread Jonathan Nieder
Hi, Ævar Arnfjörð Bjarmason wrote: > +++ b/Makefile [...] > -PERL_DEFINES = $(PERL_PATH_SQ):$(PERLLIB_EXTRA_SQ) > -$(SCRIPT_PERL_GEN): % : %.perl perl/perl.mak GIT-PERL-DEFINES > GIT-VERSION-FILE > +PERL_DEFINES = $(PERL_PATH_SQ):$(PERLLIB_EXTRA_SQ):$(perllibdir_SQ) > +$(SCRIPT_PERL_GEN): % :

Re: [PATCH v3 1/1] convert_to_git(): checksafe becomes int conv_flags

2018-01-02 Thread Lars Schneider
> On 01 Jan 2018, at 22:59, tbo...@web.de wrote: > > From: Torsten Bögershausen > > When calling convert_to_git(), the checksafe parameter has been used to > check if commit would give a non-roundtrip conversion of EOL. > > When checksafe was introduced, 3 values had been in

Re: [PATCH] oidmap.h: strongly discourage using OIDMAP_INIT directly

2018-01-02 Thread Jeff Hostetler
On 12/22/2017 12:16 PM, Brandon Williams wrote: On 12/22, Johannes Schindelin wrote: [...] That pattern is violated by OIDMAP_INIT, though. The first call to oidmap_put() or oidmap_get() will succeed, but by mistake rather than by design: The underlying hashmap is not initialized correctly,

[PATCH] doc/SubmittingPatches: improve text formatting

2018-01-02 Thread Todd Zullinger
049e64aa50 ("Documentation: convert SubmittingPatches to AsciiDoc", 2017-11-12) changed the `git blame` and `git shortlog` examples given in the section on sending your patches. In order to italicize the `$path` argument the commands are enclosed in plus characters as opposed to backticks. The

Re: Test failure for v2.16.0-rc0 on cygwin

2018-01-02 Thread Ramsay Jones
On 02/01/18 11:36, Adam Dinwoodie wrote: > On Saturday 30 December 2017 at 02:40 pm +, Adam Dinwoodie wrote: >> On Saturday 30 December 2017 at 02:21 pm +, Ramsay Jones wrote: >>> Hi Junio, Adam, >>> >>> Just a quick note about the failure of the test-suite on cygwin. >>> In particular,

Re: Git removes existing folder when cancelling clone

2018-01-02 Thread Robert P. J. Day
On Tue, 2 Jan 2018, Stephan Janssen wrote: > Hi, > > I hope this mailing list is the right way to communicate this. > > I just noticed the following behaviour on macOS 10.13.2 running Git v2.15.0: > > 1. `mkdir new-folder` > 2. `ls` - shows new-folder > 3. `git clone [repo] new-folder` > 4. Git

Re: Test failure for v2.16.0-rc0 on cygwin

2018-01-02 Thread Adam Dinwoodie
On Saturday 30 December 2017 at 02:40 pm +, Adam Dinwoodie wrote: > On Saturday 30 December 2017 at 02:21 pm +, Ramsay Jones wrote: > > Hi Junio, Adam, > > > > Just a quick note about the failure of the test-suite on cygwin. > > In particular, test t5580-clone-push-unc.sh #3, like so: > >

Git removes existing folder when cancelling clone

2018-01-02 Thread Stephan Janssen
Hi, I hope this mailing list is the right way to communicate this. I just noticed the following behaviour on macOS 10.13.2 running Git v2.15.0: 1. `mkdir new-folder` 2. `ls` - shows new-folder 3. `git clone [repo] new-folder` 4. Git asks for password 5. I cancel by pressing ctrl+c Result: `ls`

Re: [PATCH 4/4] branch: add '--show-description' option

2018-01-02 Thread SZEDER Gábor
On Tue, Jan 2, 2018 at 10:32 AM, Johannes Sixt wrote: > Am 01.01.2018 um 23:54 schrieb SZEDER Gábor: >>- errors out with a proper error message when the given branch >> doesn't exist (but exits quietly with an error code when the >> branch does exit but has no

Re: [PATCH 4/4] branch: add '--show-description' option

2018-01-02 Thread SZEDER Gábor
On Tue, Jan 2, 2018 at 6:17 AM, Eric Sunshine wrote: > On Mon, Jan 1, 2018 at 5:54 PM, SZEDER Gábor wrote: > s/exit/exist/ Thanks. >> query does). >> >> Signed-off-by: SZEDER Gábor >> --- >> diff --git

Re: Segfault

2018-01-02 Thread Andrew Tsykhonya
I made: $git stash $git checkout $git stash pop - crash here. changes were applied, but index.lock was not removed. The issue appeared only once, I haven't seen it before and cannot reproduce it now. Thanks, updated git to 2.15.1. 2017-12-31 10:59 GMT+02:00 Eric Sunshine

Re: [PATCH 4/4] branch: add '--show-description' option

2018-01-02 Thread Johannes Sixt
Am 01.01.2018 um 23:54 schrieb SZEDER Gábor: 'git branch' has an option to edit a branch's description, but lacks the option to show that description. Therefore, add a new '--show-description' option to do just that, as a more user-friendly alternative to 'git config --get