Re: [PATCH v9 01/11] ref-filter: print output to strbuf for formatting

2015-08-06 Thread Eric Sunshine
On Tue, Aug 4, 2015 at 8:42 AM, Karthik Nayak karthik@gmail.com wrote: Introduce a strbuf `output` which will act as a substitute rather than printing directly to stdout. This will be used for formatting eventually. Signed-off-by: Karthik Nayak karthik@gmail.com --- diff --git

Re: [PATCH] submodule: implement `module_name` as a builtin helper

2015-08-06 Thread Jens Lehmann
Am 05.08.2015 um 23:08 schrieb Stefan Beller: This implements the helper `module_name` in C instead of shell, yielding a nice performance boost. Before this patch, I measured a time (best out of three): $ time ./t7400-submodule-basic.sh /dev/null real 0m11.066s user

Re: [RFC/PATCH 0/4] parallel fetch for submodules

2015-08-06 Thread Jens Lehmann
Am 06.08.2015 um 19:35 schrieb Stefan Beller: When I was looking at the branches of Jens for work done on submodules not yet upstream I found a commit WIP threaded submodule fetching[1], and I was side tracked wanting to present a different approach to that. Cool. I didn't follow that route

Re: [RFC/PATCH 0/4] parallel fetch for submodules

2015-08-06 Thread Stefan Beller
On Thu, Aug 6, 2015 at 1:08 PM, Jens Lehmann jens.lehm...@web.de wrote: Am 06.08.2015 um 19:35 schrieb Stefan Beller: When I was looking at the branches of Jens for work done on submodules not yet upstream I found a commit WIP threaded submodule fetching[1], and I was side tracked wanting to

Re: [PATCH v2 1/3] test_terminal: redirect child process' stdin to a pty

2015-08-06 Thread Eric Sunshine
On Tue, Aug 4, 2015 at 10:08 AM, Paul Tan pyoka...@gmail.com wrote: When resuming, git-am detects if we are trying to feed it patches or not by checking if stdin is a TTY. However, the test library redirects stdin to /dev/null. This makes it difficult, for instance, to test the behavior of

Re: [PATCH 1/4] submodule: implement `module_name` as a builtin helper

2015-08-06 Thread Jens Lehmann
Am 06.08.2015 um 19:35 schrieb Stefan Beller: This implements the helper `module_name` in C instead of shell, yielding a nice performance boost. Before this patch, I measured a time (best out of three): $ time ./t7400-submodule-basic.sh /dev/null real 0m11.066s user

Re: Draft of Git Rev News edition 6

2015-08-06 Thread Thomas Ferris Nicolaisen
On Mon, Aug 3, 2015 at 10:49 PM, Thomas Ferris Nicolaisen tfn...@gmail.com wrote: I hope we can attract more contributors in the future, so the weight of this doesn't lie too much on his shoulders. Perhaps we should send out the draft earlier next time, and beckon for more contributions from

Re: [PATCH 1/2] builtin/mv: remove get_pathspec()

2015-08-06 Thread Stefan Beller
On Thu, Aug 6, 2015 at 1:18 PM, Eric Sunshine sunsh...@sunshineco.com wrote: On Thu, Aug 6, 2015 at 2:58 PM, Stefan Beller sbel...@google.com wrote: On Thu, Aug 6, 2015 at 11:46 AM, Eric Sunshine sunsh...@sunshineco.com wrote: On Thu, Aug 6, 2015 at 2:27 PM, Stefan Beller sbel...@google.com

Re: [PATCH] sha1_file.c: fix a declaration-after-statement

2015-08-06 Thread Ramsay Jones
On 06/08/15 10:53, Ramsay Jones wrote: Signed-off-by: Ramsay Jones ram...@ramsay1.demon.co.uk --- Hi Junio, Sorry for this hit-n-run patch, but I'm in a hurry ... :-D Could you please squash this (or something like it) into the relevant patch; Thanks! Ah, I've just read your 'What's

Re: What's cooking in git.git

2015-08-06 Thread Johannes Schindelin
Hi Junio, On 2015-08-06 00:55, Junio C Hamano wrote: * sb/submodule-helper (2015-08-05) 1 commit - submodule: implement `module_list` as a builtin helper The beginning of git submodule rewritten in C. I am really looking forward to that, with my Windows performance hat firmly on my

Re: [PATCH v4 1/3] clone: do not include authentication data in guessed dir

2015-08-06 Thread Patrick Steinhardt
On Wed, Aug 05, 2015 at 12:41:27PM -0700, Junio C Hamano wrote: Junio C Hamano gits...@pobox.com writes: For completeness, here is what I think the end result (together with Peff's series) of the test should look like. ... Note that ssh://user:passw@rd@host:1234/ and

[PATCH] sha1_file.c: fix a declaration-after-statement

2015-08-06 Thread Ramsay Jones
Signed-off-by: Ramsay Jones ram...@ramsay1.demon.co.uk --- Hi Junio, Sorry for this hit-n-run patch, but I'm in a hurry ... :-D Could you please squash this (or something like it) into the relevant patch; Thanks! [I noticed this simply because I have '-Wdeclaration-after-statement' and

[PATCH] submodule: implement `module_name` as a builtin helper

2015-08-06 Thread Stefan Beller
This implements the helper `module_name` in C instead of shell, yielding a nice performance boost. Before this patch, I measured a time (best out of three): $ time ./t7400-submodule-basic.sh /dev/null real0m11.066s user0m3.348s sys 0m8.534s With this patch applied

Re: [PATCH v9 02/11] ref-filter: introduce ref_formatting_state

2015-08-06 Thread Eric Sunshine
On Thu, Aug 6, 2015 at 11:53 PM, Karthik Nayak karthik@gmail.com wrote: On Fri, Aug 7, 2015 at 5:49 AM, Eric Sunshine sunsh...@sunshineco.com wrote: On Tue, Aug 4, 2015 at 8:42 AM, Karthik Nayak karthik@gmail.com wrote: +static void apply_formatting_state(struct ref_formatting_state

Re: [PATCH v9 01/11] ref-filter: print output to strbuf for formatting

2015-08-06 Thread Karthik Nayak
On Fri, Aug 7, 2015 at 3:51 AM, Eric Sunshine sunsh...@sunshineco.com wrote: On Tue, Aug 4, 2015 at 8:42 AM, Karthik Nayak karthik@gmail.com wrote: Introduce a strbuf `output` which will act as a substitute rather than printing directly to stdout. This will be used for formatting

Re: [PATCH v9 02/11] ref-filter: introduce ref_formatting_state

2015-08-06 Thread Eric Sunshine
On Tue, Aug 4, 2015 at 8:42 AM, Karthik Nayak karthik@gmail.com wrote: Introduce a ref_formatting_state which will eventually hold the values of modifier atoms. Implement this within ref-filter. Signed-off-by: Karthik Nayak karthik@gmail.com --- diff --git a/ref-filter.c

Re: [PATCH v9 02/11] ref-filter: introduce ref_formatting_state

2015-08-06 Thread Karthik Nayak
On Fri, Aug 7, 2015 at 5:49 AM, Eric Sunshine sunsh...@sunshineco.com wrote: On Tue, Aug 4, 2015 at 8:42 AM, Karthik Nayak karthik@gmail.com wrote: Introduce a ref_formatting_state which will eventually hold the values of modifier atoms. Implement this within ref-filter. Signed-off-by:

Re: [PATCH v9 03/11] ref-filter: implement an `align` atom

2015-08-06 Thread Eric Sunshine
On Wed, Aug 5, 2015 at 2:54 PM, Karthik Nayak karthik@gmail.com wrote: Implement an `align` atom which will act as a modifier atom and align any string with or without an %(atom) appearing before a %(end) atom to the right, left or middle. It is followed by `:type,paddinglength`, where

Re: [PATCH v9 03/11] ref-filter: implement an `align` atom

2015-08-06 Thread Eric Sunshine
On Wed, Aug 5, 2015 at 2:54 PM, Karthik Nayak karthik@gmail.com wrote: Implement an `align` atom which will act as a modifier atom and align any string with or without an %(atom) appearing before a %(end) atom to the right, left or middle. For someone not familiar with the evolution of

Re: Draft of Git Rev News edition 6

2015-08-06 Thread Mikael Magnusson
On Fri, Aug 7, 2015 at 12:18 AM, Thomas Ferris Nicolaisen tfn...@gmail.com wrote: On Mon, Aug 3, 2015 at 10:49 PM, Thomas Ferris Nicolaisen tfn...@gmail.com wrote: I hope we can attract more contributors in the future, so the weight of this doesn't lie too much on his shoulders. Perhaps we

Re: [PATCH v3 3/4] notes: add notes.merge option to select default strategy

2015-08-06 Thread Eric Sunshine
On Sun, Aug 2, 2015 at 6:10 AM, Jacob Keller jacob.e.kel...@intel.com wrote: Teach git-notes about a new configuration option notes.merge for selecting the default notes merge strategy. Document the option in config.txt and git-notes.txt Add tests for use of the configuration option. Include

Re: Draft of Git Rev News edition 6

2015-08-06 Thread Thomas Ferris Nicolaisen
On Fri, Aug 7, 2015 at 1:44 AM, Mikael Magnusson mika...@gmail.com wrote: It is surprisingly difficult to get to the actual post of edition 6 from this thread. The link in the original post is just a 404, and to get to it from the link in this mail, which you might not have sent at all, I had

Re: [PATCH v9 02/11] ref-filter: introduce ref_formatting_state

2015-08-06 Thread Eric Sunshine
On Tue, Aug 4, 2015 at 8:42 AM, Karthik Nayak karthik@gmail.com wrote: Introduce a ref_formatting_state which will eventually hold the values of modifier atoms. Implement this within ref-filter. Signed-off-by: Karthik Nayak karthik@gmail.com --- +static void

wishlist: make it possible to amend commit messages after push to remote

2015-08-06 Thread Jarkko Hietaniemi
Not for the first time, and probably not for the last, I pushed a commit upstream without adding a link for the bug report as I was meaning to. Or it could have been... - Simple typos. - Broken URLs. - The impossibility of two consecutive commits referring to each other because the older one

[RFC PATCH 2/4] Add a workdispatcher to get work done in parallel

2015-08-06 Thread Stefan Beller
This adds infrastructure code to work a set of tasks from a thread pool. The whole life cycle of such a thread pool would look like struct workdispatcher *wd; struct return_values *rv; wd = create_workdispatcher(command_for_task, max_parallel_jobs); for (...) {

Re: fetching from an hg remote fails with bare git repositories

2015-08-06 Thread Taylor Braun-Jones
On Tue, Aug 4, 2015 at 7:03 PM, Mike Hommey m...@glandium.org wrote: Another missing detail is what you're using for mercurial support in git. I would guess https://github.com/felipec/git-remote-hg. Yes. I was going off some outdated information on the web that told me the felipec/git-remote-hg

Re: [PATCH 1/2] builtin/mv: remove get_pathspec()

2015-08-06 Thread Stefan Beller
On Thu, Aug 6, 2015 at 11:46 AM, Eric Sunshine sunsh...@sunshineco.com wrote: On Thu, Aug 6, 2015 at 2:27 PM, Stefan Beller sbel...@google.com wrote: builtin/mv: remove get_pathspec() Misleading. Perhaps rephrase as: mv: drop dependency upon deprecated get_pathspec `get_pathspec` is

Re: [PATCH 3/4] argv_array: add argv_array_copy

2015-08-06 Thread Jeff King
On Thu, Aug 06, 2015 at 02:18:26PM -0400, Eric Sunshine wrote: However, that begs the question: Why do you need argv_array_copy() at all? Isn't the same functionality already provided by argv_array_pushv()? To wit, a caller which wants to copy from 'src' to 'dst' can already do: struct

Re: [PATCH 3/4] argv_array: add argv_array_copy

2015-08-06 Thread Eric Sunshine
On Thu, Aug 6, 2015 at 1:35 PM, Stefan Beller sbel...@google.com wrote: The copied argv array shall be an identical deep copy except for the internal allocation value. Signed-off-by: Stefan Beller sbel...@google.com --- diff --git a/argv-array.c b/argv-array.c index 256741d..6d9c1dd 100644

[RFC PATCH 4/4] submodule: add infrastructure to fetch submodules in parallel

2015-08-06 Thread Stefan Beller
This makes use of the new workdispatcher to fetch a number of submodules at the same time. Still todo: sort the output of the fetch commands. I am unsure if this should be hooked into the workdispatcher as the problem of sorted output will appear likely again, so a general solution would not

[RFC/PATCH 0/4] parallel fetch for submodules

2015-08-06 Thread Stefan Beller
When I was looking at the branches of Jens for work done on submodules not yet upstream I found a commit WIP threaded submodule fetching[1], and I was side tracked wanting to present a different approach to that. The first patch is a bit unrelated as it relates to the rewrite of git-submodule.sh

[PATCH 3/4] argv_array: add argv_array_copy

2015-08-06 Thread Stefan Beller
The copied argv array shall be an identical deep copy except for the internal allocation value. CC: Jeff King p...@peff.net Signed-off-by: Stefan Beller sbel...@google.com --- argv-array.c | 13 + argv-array.h | 1 + 2 files changed, 14 insertions(+) diff --git a/argv-array.c

[PATCH 1/4] submodule: implement `module_name` as a builtin helper

2015-08-06 Thread Stefan Beller
This implements the helper `module_name` in C instead of shell, yielding a nice performance boost. Before this patch, I measured a time (best out of three): $ time ./t7400-submodule-basic.sh /dev/null real0m11.066s user0m3.348s sys 0m8.534s With this patch applied

Re: [PATCH 1/2] builtin/mv: remove get_pathspec()

2015-08-06 Thread Eric Sunshine
On Thu, Aug 6, 2015 at 2:27 PM, Stefan Beller sbel...@google.com wrote: builtin/mv: remove get_pathspec() Misleading. Perhaps rephrase as: mv: drop dependency upon deprecated get_pathspec `get_pathspec` is deprecated and builtin/mv.c is its last caller, so reimplement `get_pathspec`

[PATCH 2/2] pathspec: remove deprecated get_pathspec

2015-08-06 Thread Stefan Beller
The function `get_pathspec` is no longer used, so remove it. The NEEDSWORK comment in pathspec.c is outdated as that happened in (fadf96aba, 2013-09-09, Merge branch 'nd/magic-pathspec') Signed-off-by: Stefan Beller sbel...@google.com --- Documentation/technical/api-setup.txt | 2 -- cache.h

[PATCH 0/2] Remove get_pathspec finally

2015-08-06 Thread Stefan Beller
Remove the last caller of the get_pathspec function and the get_pathspec function itself. I stumbled into this as I was reading the documentation on pathspec, and the first sentence get_pathspec() is obsolete and should never be used in new code. made me wonder. This replaces

[PATCH 1/2] builtin/mv: remove get_pathspec()

2015-08-06 Thread Stefan Beller
`get_pathspec` is deprecated and builtin/mv.c is its last caller, so reimplement `get_pathspec` literally in builtin/mv.c Signed-off-by: Stefan Beller sbel...@google.com --- builtin/mv.c | 16 +--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/builtin/mv.c

Re: [PATCH/RFC] gitweb: Don't pass --full-history to git-log(1)

2015-08-06 Thread Junio C Hamano
Junio C Hamano gits...@pobox.com writes: Heh, in 2008 we already had more than a few dozen. I think (1) It is perfectly OK to add an UI option to let the web visitor choose between simplified and full history at runtime, optionally with a new gitweb.conf option to let the

Re: Error when cloning with weird local directory

2015-08-06 Thread Junio C Hamano
Junio C Hamano gits...@pobox.com writes: Torsten Bögershausen tbo...@web.de writes: It looks as if static char *get_repo_path(const char *repo, int *is_bundle) in built/clone.c checks if there is a local directory structure looking like a .git directory. This is wrong. It is as

Re: Error when cloning with weird local directory

2015-08-06 Thread Junio C Hamano
Torsten Bögershausen tbo...@web.de writes: It looks as if static char *get_repo_path(const char *repo, int *is_bundle) in built/clone.c checks if there is a local directory structure looking like a .git directory. This is wrong. It is as designed, though, to allow cloning from a local

Re: [PATCH v3 0/6] fix repo name when cloning a server's root

2015-08-06 Thread Torsten Bögershausen
On 2015-08-05 23.19, Jeff King wrote: On Wed, Aug 05, 2015 at 10:34:34AM -0700, Junio C Hamano wrote: As you can see, there is a lot of complexity in there and I'm not convinced this is better than just exposing 'parse_connect_url()', which already handles everything for us. I try expose and

Re: [PATCH v3 0/6] fix repo name when cloning a server's root

2015-08-06 Thread Junio C Hamano
Torsten Bögershausen tbo...@web.de writes: It is easy to strip the foo:: part of the url, assume that the remote helper uses a RFC 3986 similar url syntax, so that we can feed the reminding https://host/repo.git into the parser (see above). The thing that worries me is that foo:: syntax and

Re: [RFC/PATCH] contrib: teach completion about git-worktree options and arguments

2015-08-06 Thread Eric Sunshine
On Thu, Jul 23, 2015 at 4:49 PM, Eric Sunshine sunsh...@sunshineco.com wrote: Complete subcommands 'add' and 'prune', as well as their respective options --force, --detach, --dry-run, --verbose, and --expire. Also complete 'refname' in git worktree add [-b newbranch] path refname. Ping[1]?