[PATCH] read-tree: replace bracket set with parentheses to clarify usage

2015-08-26 Thread Alex Henrie
-u and -i can only be given if -m, --reset, or --prefix is given. Without parentheses, it looks like -u and -i can be used no matter what, and the second pair of brackets is confusing. Signed-off-by: Alex Henrie --- builtin/read-tree.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff

[PATCH] show-ref: place angle brackets around variable in usage string

2015-08-26 Thread Alex Henrie
Signed-off-by: Alex Henrie --- builtin/show-ref.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builtin/show-ref.c b/builtin/show-ref.c index dfbc314..d9c1633 100644 --- a/builtin/show-ref.c +++ b/builtin/show-ref.c @@ -8,7 +8,7 @@ static const char * const show_ref_usage

[PATCH] pack-objects: place angle brackets around variables in usage strings

2015-08-26 Thread Alex Henrie
Signed-off-by: Alex Henrie --- builtin/pack-objects.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/builtin/pack-objects.c b/builtin/pack-objects.c index 62cc16d..1c63f8f 100644 --- a/builtin/pack-objects.c +++ b/builtin/pack-objects.c @@ -25,8 +25,8 @@ #include "argv-a

[PATCH] git-submodule: remove extraneous space from error message

2015-08-26 Thread Alex Henrie
Signed-off-by: Alex Henrie --- git-submodule.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/git-submodule.sh b/git-submodule.sh index 36797c3..25b1ddf 100755 --- a/git-submodule.sh +++ b/git-submodule.sh @@ -904,7 +904,7 @@ Maybe you want to use 'update --init'?")"

[PATCH] reflog: add missing single quote to error message

2015-08-26 Thread Alex Henrie
The error message can be seen by running `git config gc.reflogexpire foo` and then `git reflog expire`. Signed-off-by: Alex Henrie --- builtin/reflog.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builtin/reflog.c b/builtin/reflog.c index 7ed0e85..f96ca2a 100644 --- a/buil

[PATCH 2/5] thread-utils: add a threaded task queue

2015-08-26 Thread Stefan Beller
This adds functionality to do work in a parallel threaded fashion while the boiler plate code for setting up threads and tearing them down as well as queuing up tasks is hidden behind the new API. Signed-off-by: Stefan Beller --- run-command.c | 29 +--- thread-utils.c | 227 ++

[PATCH 3/5] submodule: helper to run foreach in parallel

2015-08-26 Thread Stefan Beller
Similar to `git submodule foreach` the new command `git submodule foreach_parallel` will run a command on each submodule. The commands are run in parallel up to the number of cores by default, or you can specify '-j 4' tun just run with 4 threads for example. One major difference to `git submodul

[PATCH 4/5] index-pack: Use the new worker pool

2015-08-26 Thread Stefan Beller
This demonstrates how the new threading API may be used. There is no change in the workflow, just using the new threading API instead of keeping track of the pthreads ourselves. Signed-off-by: Stefan Beller --- builtin/index-pack.c | 23 --- 1 file changed, 12 insertions(+),

[PATCH 5/5] pack-objects: Use new worker pool

2015-08-26 Thread Stefan Beller
Before we had threads doing the delta finding work, and the main thread was load balancing the threads, i.e. moving work from a thread with a large amount left to an idle thread whenever such a situation arose. This moves the load balancing to the threads themselves. As soon as one thread is done

[PATCH 1/5] submodule: implement `module_clone` as a builtin helper

2015-08-26 Thread Stefan Beller
`module_clone` is part of the update command, which I want to convert to C next. Signed-off-by: Stefan Beller Signed-off-by: Junio C Hamano --- builtin/submodule--helper.c | 160 +++- git-submodule.sh| 80 +- 2 files chang

[RFC PATCH 0/5] Progressing with `git submodule foreach_parallel`

2015-08-26 Thread Stefan Beller
This series applies on top of 10d0bef9981c8045b8c9aac1ca7b8761896bed0c in the branch origin/sb/submodule-helper The first patch is a resend of module_clone, which now contains all memory leak fixes. The second patch adding the new task queue is rewritten to not use semaphores any more, but only

Re: Git's inconsistent command line options

2015-08-26 Thread Jacob Keller
On Wed, Aug 26, 2015 at 4:02 PM, Jacob Keller wrote: > On Wed, Aug 26, 2015 at 3:52 PM, Philip Oakley wrote: >> From: "Jacob Keller" >>> >>> On Wed, Aug 26, 2015 at 10:56 AM, Junio C Hamano >>> wrote: But notice that I said "if you really want to". I personally think it is a roa

Re: Git's inconsistent command line options

2015-08-26 Thread Jacob Keller
On Wed, Aug 26, 2015 at 3:52 PM, Philip Oakley wrote: > From: "Jacob Keller" >> >> On Wed, Aug 26, 2015 at 10:56 AM, Junio C Hamano >> wrote: >>> >>> But notice that I said "if you really want to". I personally think >>> it is a road to madness. >> >> >> Agreed. I don't believe in command line

Re: Git's inconsistent command line options

2015-08-26 Thread Philip Oakley
From: "Jacob Keller" On Wed, Aug 26, 2015 at 10:56 AM, Junio C Hamano wrote: But notice that I said "if you really want to". I personally think it is a road to madness. Agreed. I don't believe in command line API here. I think we'd need a better solution. My gut says: Live with the warts o

Re: [PATCH] git-send-email: Delete additional From message body

2015-08-26 Thread Junio C Hamano
brillian...@inbox.ru writes: > Additional From added to message body if git-send-email run > with --from parameters > > Signed-off-by: Brilliantov Kirill Vladimirovich > --- > git-send-email.perl | 25 +++-- > 1 file changed, 11 insertions(+), 14 deletions(-) > > diff --git a

Re: [PATCH v4 2/4] path: optimize common dir checking

2015-08-26 Thread David Turner
On Wed, 2015-08-26 at 18:10 -0400, David Turner wrote: > On Wed, 2015-08-26 at 14:15 -0700, Junio C Hamano wrote: > > > + * For example, consider the following set of strings: > > > + * abc > > > + * def > > > + * definite > > > + * definition > > > + * > > > + * The trie would look look like: > >

Re: [PATCH v4 2/4] path: optimize common dir checking

2015-08-26 Thread Junio C Hamano
David Turner writes: > On Wed, 2015-08-26 at 14:15 -0700, Junio C Hamano wrote: > >> Thanks for a pleasant read. > > Thank you! I'll re-roll with those last two fixes (re value=NULL) > tomorrow-ish. If these two "value = NULL" are the only things, I can locally fix them up. No need to resend.

Re: [PATCH v4 2/4] path: optimize common dir checking

2015-08-26 Thread David Turner
On Wed, 2015-08-26 at 14:15 -0700, Junio C Hamano wrote: > > + * For example, consider the following set of strings: > > + * abc > > + * def > > + * definite > > + * definition > > + * > > + * The trie would look look like: > > + * root: len = 0, value = (something), children a and d non-NULL. > >

Re: [PATCH v6] git-p4: Obey core.ignorecase when using P4 client specs.

2015-08-26 Thread Junio C Hamano
Lars Schneider writes: > On 26 Aug 2015, at 22:05, Junio C Hamano wrote: > >> larsxschnei...@gmail.com writes: >> >>> From: Lars Schneider >>> >>> We run P4 servers on Linux and P4 clients on Windows. For an unknown >>> reason the file path for a number of files in P4 does not match the >>> d

Re: [PATCH v6] git-p4: Obey core.ignorecase when using P4 client specs.

2015-08-26 Thread Lars Schneider
On 26 Aug 2015, at 22:05, Junio C Hamano wrote: > larsxschnei...@gmail.com writes: > >> From: Lars Schneider >> >> We run P4 servers on Linux and P4 clients on Windows. For an unknown >> reason the file path for a number of files in P4 does not match the >> directory path with respect to case

Re: [PATCH v4 2/4] path: optimize common dir checking

2015-08-26 Thread Junio C Hamano
David Turner writes: > Instead of a linear search over common_list to check whether > a path is common, use a trie. The trie search operates on > path prefixes, and handles excludes. > > Signed-off-by: David Turner > --- > path.c| 226 >

[PATCH] tag: teach -n to override tag.sort configuration

2015-08-26 Thread Jacob Keller
From: Jacob Keller git tag -n will always fail if tag.sort is set to a sort other than the default "refname" setting. Teach git tag to have -n override the configuration setting when -n is used, instead of failing with fatal: --sort and -n incompatible since the user probably sets tag.sort once

Re: Git's inconsistent command line options

2015-08-26 Thread Junio C Hamano
Jacob Keller writes: > On Wed, Aug 26, 2015 at 10:56 AM, Junio C Hamano wrote: >> But notice that I said "if you really want to". I personally think >> it is a road to madness. > > Agreed. I don't believe in command line API here. I think we'd need a > better solution. > > My gut says: Live wit

git clone svn: authors from authors file are ignored, authors-prog works, but crashes on branch points

2015-08-26 Thread Till Schäfer
Hi, i am observing some weired "git svn clone" behavior during my try to migrate the Scaffold Hunter [1] SVN repository [2] to Git: if i just use the command $ git svn clone svn://svn.code.sf.net/p/scaffoldhunter/code --no-metadata -s code everything went smoothly. Now i wanted to replace th

Re: [PATCH v13 00/12] port tag.c to use ref-filter APIs

2015-08-26 Thread Junio C Hamano
Karthik Nayak writes: > On Wed, Aug 26, 2015 at 8:07 PM, Junio C Hamano wrote: >> >> ... You can give a new format_ref_array_item() >> that does not print but fills a strbuf to this caller, make >> show_ref_array_item() a thin wrapper that calls it and prints it >> with the final LF for other c

Re: [PATCH v6] git-p4: Obey core.ignorecase when using P4 client specs.

2015-08-26 Thread Junio C Hamano
larsxschnei...@gmail.com writes: > From: Lars Schneider > > We run P4 servers on Linux and P4 clients on Windows. For an unknown > reason the file path for a number of files in P4 does not match the > directory path with respect to case sensitivity. Thanks, but is this still "For an unknown reas

Re: [PATCH v2 2/2] trailer: support multiline title

2015-08-26 Thread Junio C Hamano
Christian Couder writes: > We currently ignore the first line passed to `git interpret-trailers`, > when looking for the beginning of the trailers. > > Unfortunately this does not work well when a commit is created with a > line break in the title, using for example the following command: > > git

[PATCH v4 1/4] refs: clean up common_list

2015-08-26 Thread David Turner
Instead of common_list having formatting like ! and /, use a struct to hold common_list data in a structured form. We don't use 'exclude' yet; instead, we keep the old codepath that handles info/sparse-checkout and logs/HEAD. Later, we will use exclude. Signed-off-by: David Turner --- path.c |

[PATCH v4 2/4] path: optimize common dir checking

2015-08-26 Thread David Turner
Instead of a linear search over common_list to check whether a path is common, use a trie. The trie search operates on path prefixes, and handles excludes. Signed-off-by: David Turner --- path.c| 226 ++ t/t0060-path-utils.sh | 1

[PATCH v4 3/4] refs: make refs/worktree/* per-worktree

2015-08-26 Thread David Turner
We need a place to stick refs for bisects in progress that is not shared between worktrees. So we use the refs/worktree/ hierarchy. The is_per_worktree_ref function and associated docs learn that refs/worktree/ is per-worktree, as does the git_path code in path.c The ref-packing functions learn

[PATCH v4 4/4] bisect: make bisection refs per-worktree

2015-08-26 Thread David Turner
Using the new refs/worktree/ refs, make bisection per-worktree. Signed-off-by: David Turner --- Documentation/git-bisect.txt | 4 ++-- Documentation/rev-list-options.txt | 14 +++--- bisect.c | 2 +- builtin/rev-parse.c| 6 -- git-bi

[PATCH v4 0/4] per-worktree bisection refs

2015-08-26 Thread David Turner
This reroll includes changes suggested by Duy Nguyen: A. Path normalization (partial). B. Rearrangement of common_list struct to make formatting prettier. It also includes a test style fix suggested by Eric Sunshine and others: a bogus test_must_fail on a non-git command has been replaced by a tw

Re: Re* OS X Yosemite make all doc fails

2015-08-26 Thread Torsten Bögershausen
On 2015-08-26 19.42, Junio C Hamano wrote: > Jeff S writes: > >> Brian thanks for responding! I'm finally able to build git completely. >> Would it be possible to add the OS X dependency to the git/INSTALL >> file? >> >> OSX Yosemite 10.10.5 >> Xcode 6.4 (6E35b) >> … >> $ brew install autoconf >>

Re: [PATCH v13 00/12] port tag.c to use ref-filter APIs

2015-08-26 Thread Karthik Nayak
On Wed, Aug 26, 2015 at 8:07 PM, Junio C Hamano wrote: > Karthik Nayak writes: > >> On Wed, Aug 26, 2015 at 12:46 AM, Junio C Hamano wrote: >>> Karthik Nayak writes: >>> >>> I didn't check how wide the original is supposed to be, but perhaps >>> changing builtin/tag.c this way >>> >>>

Re: [PATCH v13 00/12] port tag.c to use ref-filter APIs

2015-08-26 Thread Karthik Nayak
On Wed, Aug 26, 2015 at 9:18 PM, Matthieu Moy wrote: > Junio C Hamano writes: > >> Junio C Hamano writes: >> >>> Matthieu Moy writes: >>> > For the current code %(if:empty)%(align)%(end)%(then)Empty%(else)Not > Empty%(end) > would print non-empty, I guess the documentation holds in

Re: Git's inconsistent command line options

2015-08-26 Thread Jacob Keller
On Wed, Aug 26, 2015 at 10:56 AM, Junio C Hamano wrote: > But notice that I said "if you really want to". I personally think > it is a road to madness. Agreed. I don't believe in command line API here. I think we'd need a better solution. My gut says: Live with the warts on old commands and try

Re: Git's inconsistent command line options

2015-08-26 Thread Junio C Hamano
Hilco Wijbenga writes: > On 25 August 2015 at 16:43, Junio C Hamano wrote: >> I do not see a good way to do such a safe transition with command >> words approach, *unless* we are going to introduce new commands, >> i.e. "git list-tag", "git create-tag", etc. > > Perhaps we could introduce a more

Re* OS X Yosemite make all doc fails

2015-08-26 Thread Junio C Hamano
Jeff S writes: > Brian thanks for responding! I'm finally able to build git completely. > Would it be possible to add the OS X dependency to the git/INSTALL > file? > > OSX Yosemite 10.10.5 > Xcode 6.4 (6E35b) > … > $ brew install autoconf > $ brew install asciidoc > $ brew install xmlto > $ brew

Re: [PATCH 3/5] submodule: helper to run foreach in parallel

2015-08-26 Thread Stefan Beller
On Wed, Aug 26, 2015 at 10:06 AM, Jeff King wrote: > On Tue, Aug 25, 2015 at 10:28:24AM -0700, Stefan Beller wrote: > >> +int module_foreach_parallel(int argc, const char **argv, const char *prefix) >> +{ >> [...] >> + for (i = 0; i < ce_used; i++) { >> + const struct submodule *su

Re: [PATCH 3/5] submodule: helper to run foreach in parallel

2015-08-26 Thread Jeff King
On Tue, Aug 25, 2015 at 10:28:24AM -0700, Stefan Beller wrote: > +int module_foreach_parallel(int argc, const char **argv, const char *prefix) > +{ > [...] > + for (i = 0; i < ce_used; i++) { > + const struct submodule *sub; > + const struct cache_entry *ce = ce_entries

Re: pack negotiation algorithm between 2 share-nothing repos

2015-08-26 Thread Junio C Hamano
Junio C Hamano writes: > Duy Nguyen writes: > >> I know this is a corner case, but because it has a valid use case, >> maybe we should do something about it. Immediate reaction is to add an >> option to send no "have"s. But maybe you guys have better ideas. > > This and similar corner cases were

Re: What's cooking in git.git (Aug 2015, #04; Tue, 25)

2015-08-26 Thread Junio C Hamano
Jacob Keller writes: > On Tue, Aug 25, 2015 at 4:28 PM, Junio C Hamano wrote: >> * jk/notes-merge-config (2015-08-17) 6 commits >> - notes: teach git-notes about notes..mergeStrategy option >> - notes: add notes.mergeStrategy option to select default strategy >> - notes: add tests for --commi

Re: [PATCH v2 2/2] trailer: support multiline title

2015-08-26 Thread Matthieu Moy
Junio C Hamano writes: > While the reordering would certainly stop showing the comments and > patch, I am not sure if that is a move in the right direction. It > will rob from the hooks information that they have traditionally > been given--- The information given in the comments do not have a

Re: [PATCH v13 05/12] ref-filter: add option to filter out tags, branches and remotes

2015-08-26 Thread Michael Haggerty
Comments inline. On 08/22/2015 05:39 AM, Karthik Nayak wrote: > From: Karthik Nayak > > Add a function called 'for_each_reftype_fullpath()' to refs.{c,h} > which iterates through each ref for the given path without trimming > the path and also accounting for broken refs, if mentioned. > > Add '

[PATCH v6] git-p4: Obey core.ignorecase when using P4 client specs.

2015-08-26 Thread larsxschneider
From: Lars Schneider We run P4 servers on Linux and P4 clients on Windows. For an unknown reason the file path for a number of files in P4 does not match the directory path with respect to case sensitivity. E.g. "p4 files" might return //depot/path/to/file1 //depot/pATH/to/file2 If you use P4/P

Re: [PATCH v2 2/2] trailer: support multiline title

2015-08-26 Thread Junio C Hamano
Christian Couder writes: > There is already code to detect a patch in interpret-trailers, but it > relies on the patch starting with a line with only three dashes. Hmm, then it can be taught to notice "everything below..." as another marker, right? > Maybe. I don't know if there is a reason why

[PATCH] i18n: am: fix typo in description of -b option

2015-08-26 Thread Jiang Xin
Signed-off-by: Jiang Xin --- builtin/am.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builtin/am.c b/builtin/am.c index b9c62e3..699a924 100644 --- a/builtin/am.c +++ b/builtin/am.c @@ -2168,7 +2168,7 @@ int cmd_am(int argc, const char **argv, const char *prefix)

Re: [PATCH v13 00/12] port tag.c to use ref-filter APIs

2015-08-26 Thread Matthieu Moy
Junio C Hamano writes: > Junio C Hamano writes: > >> Matthieu Moy writes: >> For the current code %(if:empty)%(align)%(end)%(then)Empty%(else)Not Empty%(end) would print non-empty, I guess the documentation holds in that case. Not sure if we require it to print non-empty. >

Re: [PATCH v13 00/12] port tag.c to use ref-filter APIs

2015-08-26 Thread Junio C Hamano
Junio C Hamano writes: > Matthieu Moy writes: > >>> For the current code %(if:empty)%(align)%(end)%(then)Empty%(else)Not >>> Empty%(end) >>> would print non-empty, I guess the documentation holds in that case. >>> Not sure if we require it to print non-empty. >> >> You don't want the %(if) cond

Re: [PATCH v13 00/12] port tag.c to use ref-filter APIs

2015-08-26 Thread Junio C Hamano
Matthieu Moy writes: >> For the current code %(if:empty)%(align)%(end)%(then)Empty%(else)Not >> Empty%(end) >> would print non-empty, I guess the documentation holds in that case. >> Not sure if we require it to print non-empty. > > You don't want the %(if) condition to depend on whether > --she

Re: [PATCH v2 2/2] trailer: support multiline title

2015-08-26 Thread Christian Couder
Sorry I sent the part below privately by mistake: On Tue, Aug 25, 2015 at 11:07 PM, Matthieu Moy wrote: > > Now, I found another issue: I still have this "interpret-trailers" in my > hooks/commit-msg, and it behaves badly when I use "git commit -v". With > -v, I get a diff in COMMIT_EDITMSG, and

Re: [PATCH v13 00/12] port tag.c to use ref-filter APIs

2015-08-26 Thread Junio C Hamano
Karthik Nayak writes: > On Wed, Aug 26, 2015 at 12:46 AM, Junio C Hamano wrote: >> Karthik Nayak writes: >> >> I didn't check how wide the original is supposed to be, but perhaps >> changing builtin/tag.c this way >> >> if (filter->lines) >> - format = "%(a

Re: [PATCH v13 00/12] port tag.c to use ref-filter APIs

2015-08-26 Thread Matthieu Moy
Karthik Nayak writes: > On Tue, Aug 25, 2015 at 4:05 AM, Junio C Hamano wrote: >> Junio C Hamano writes: >> >>> Karthik Nayak writes: >>> On Mon, Aug 24, 2015 at 10:57 PM, Junio C Hamano wrote: > Karthik Nayak writes: > ... >> + performed. If used with '--quote' everythi

Re: [PATCH v5] git-p4: Obey core.ignorecase when using P4 client specs.

2015-08-26 Thread Luke Diamand
On 25 August 2015 at 19:24, Luke Diamand wrote: > On 25/08/15 14:14, Lars Schneider wrote: >>> >>> >>> So the choices are: >>> >>> 1. A new command-line option which would silently set core.ignorecase >>> 2. Users just have to know to set core.ignorecase manually before >>> using git-p4 (i.e. Lars

Re: [PATCH v13 00/12] port tag.c to use ref-filter APIs

2015-08-26 Thread Karthik Nayak
On Tue, Aug 25, 2015 at 4:05 AM, Junio C Hamano wrote: > Junio C Hamano writes: > >> Karthik Nayak writes: >> >>> On Mon, Aug 24, 2015 at 10:57 PM, Junio C Hamano wrote: Karthik Nayak writes: ... > + performed. If used with '--quote' everything in between %(align:..) > +

[PATCH] git-send-email: Delete additional From message body

2015-08-26 Thread brilliantov
Additional From added to message body if git-send-email run with --from parameters Signed-off-by: Brilliantov Kirill Vladimirovich --- git-send-email.perl | 25 +++-- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/git-send-email.perl b/git-send-email.perl ind

Re: [RFC] Porting builtin/branch.c to use the printing options of ref-filter.{c,h}

2015-08-26 Thread Matthieu Moy
Karthik Nayak writes: > It's more than just colors. The whole format changes. > > $ git branch -a > For local: > "%(if)%(HEAD)%(then)%(HEAD) %(color:green)%(refname:short)%(else) > %(refname:short)%(end)" > For remote: > " remotes/%(color:red)%(refname:short)%(color:reset)%(if)%(symref)%(then) >