[PATCH v6 2/3] ident: add user.useConfigOnly boolean for when ident shouldn't be guessed

2016-02-04 Thread Dan Aloni
It used to be that: git config --global user.email "(none)" was a viable way for people to force themselves to set user.email in each repository. This was helpful for people with more than one email address, targeting different email addresses for different clones, as it barred git from creat

[PATCH v6 1/3] fmt_ident: refactor strictness checks

2016-02-04 Thread Dan Aloni
From: Jeff King This function has evolved quite a bit over time, and as a result, the logic for "is this an OK ident" has been sprinkled throughout. This ends up with a lot of redundant conditionals, like checking want_name repeatedly. Worse, we want to know in many cases whether we are using the

[PATCH v6 3/3] ident: cleanup wrt ident's source

2016-02-04 Thread Dan Aloni
This change condenses the variables that tells where we got the user's ident into single enum, instead of a collection of booleans. In addtion, also have {committer,author}_ident_sufficiently_given directly probe the environment and the afformentioned enum instead of relying on git_{committer,auth

[PATCH v6] ident: add user.useConfigOnly boolean for when ident shouldn't be guessed

2016-02-04 Thread Dan Aloni
Change between v5 -> v6: * Removed trailing comma in 'enum ident_person'. v5: http://article.gmane.org/gmane.comp.version-control.git/285544 -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger

Best regards! Dear Sir or Madam! - please help our school site - пожалуйста, помогите нашему школьному сайту - будь ласка, допоможіть нашому шкільному сайту http://bilokaminsky-nvk.pp.ua/

2016-02-04 Thread admin
Best regards! Dear Sir or Madam! please at the top of any page of site click once on the advertising banner, so that we could pay for hosting our school site, Thank you ad...@bilokaminsky-nvk.pp.ua http://bilokaminsky-nvk.pp.ua/ добрий день, просимо на будь-якій сторінці вгорі один раз натиснути

[PATCH v5 3/3] ident: cleanup wrt ident's source

2016-02-04 Thread Dan Aloni
This change condenses the variables that tells where we got the user's ident into single enum, instead of a collection of booleans. In addtion, also have {committer,author}_ident_sufficiently_given directly probe the environment and the afformentioned enum instead of relying on git_{committer,auth

[PATCH v5 2/3] ident: add user.useConfigOnly boolean for when ident shouldn't be guessed

2016-02-04 Thread Dan Aloni
It used to be that: git config --global user.email "(none)" was a viable way for people to force themselves to set user.email in each repository. This was helpful for people with more than one email address, targeting different email addresses for different clones, as it barred git from creat

[PATCH v5] ident: add user.useConfigOnly boolean for when ident shouldn't be guessed

2016-02-04 Thread Dan Aloni
Changes between v4 -> v5: * Fixes for compiler warnings under standard compilation. * Revised commit messages according to remarks. * Cleanups and fixes of the added test script. * Indentation and styling fixes. v4: http://thread.gmane.org/gmane.comp.version-control.git/285441 -- To unsubscr

[PATCH v5 1/3] fmt_ident: refactor strictness checks

2016-02-04 Thread Dan Aloni
From: Jeff King This function has evolved quite a bit over time, and as a result, the logic for "is this an OK ident" has been sprinkled throughout. This ends up with a lot of redundant conditionals, like checking want_name repeatedly. Worse, we want to know in many cases whether we are using the

Re: [PATCH v4 2/3] Add user.useConfigOnly boolean for when ident shouldn't be guessed

2016-02-04 Thread Dan Aloni
On Thu, Feb 04, 2016 at 01:53:25PM -0800, Junio C Hamano wrote: >[..] > "by adding a new configuration variable" is a bit weak. Help the > reader by mentioning what it is called and what it does in the same > sentence. > > Perhaps like this? > > -- >8 -- >[..] > Looks good, I'll just take that

Re: [PATCH v4 3/3] ident.c: cleanup wrt ident's source

2016-02-04 Thread Dan Aloni
On Thu, Feb 04, 2016 at 02:42:55PM -0800, Junio C Hamano wrote: > Dan Aloni writes: > > > +static int ident_source_is_sufficient(enum ident_source source) > > +{ > > + switch (source) { > > + case IDENT_SOURCE_CONFIG: > > + case IDENT_SOURCE_ENVIRONMENT: > > + return 1; > > Witho

Re: [PATCH v2 24/25] upload-pack: make check_reachable_object() return unreachable list if asked

2016-02-04 Thread Eric Sunshine
On Thu, Feb 4, 2016 at 4:04 AM, Nguyễn Thái Ngọc Duy wrote: > Signed-off-by: Nguyễn Thái Ngọc Duy > --- > diff --git a/upload-pack.c b/upload-pack.c > @@ -451,8 +451,16 @@ static int is_our_ref(struct object *o) > -static int check_unreachable(struct object_array *src) > +/* > + * If reachable is

Re: [PATCH v2 21/25] fetch: define shallow boundary with --shallow-exclude

2016-02-04 Thread Eric Sunshine
On Thu, Feb 4, 2016 at 4:03 AM, Nguyễn Thái Ngọc Duy wrote: > Signed-off-by: Nguyễn Thái Ngọc Duy > --- > diff --git a/builtin/fetch-pack.c b/builtin/fetch-pack.c > @@ -109,6 +109,16 @@ int cmd_fetch_pack(int argc, const char **argv, const > char *prefix) > + if (skip_prefix(arg, "

Re: [PATCH v2 20/25] upload-pack: support define shallow boundary by excluding revisions

2016-02-04 Thread Eric Sunshine
On Thu, Feb 4, 2016 at 4:03 AM, Nguyễn Thái Ngọc Duy wrote: > @@ -732,7 +743,7 @@ static void receive_needs(void) > if (depth == 0 && !deepen_rev_list && shallows.nr == 0) > return; > if (depth > 0 && deepen_rev_list) > - die("--depth and --shallow-sin

Re: [PATCH v2 20/25] upload-pack: support define shallow boundary by excluding revisions

2016-02-04 Thread Eric Sunshine
On Thu, Feb 4, 2016 at 4:03 AM, Nguyễn Thái Ngọc Duy wrote: > This should allow the user to say "create a shallow clone of this branch > after version ". > > deepen-not cannot be used with deepen the same way deepen-since cannot > be used with deepen. As written, this is a bit of a brain twister

Re: [PATCH v2 13/25] fetch-pack: use a separate flag for fetch in deepening mode

2016-02-04 Thread Eric Sunshine
On Thu, Feb 4, 2016 at 4:03 AM, Nguyễn Thái Ngọc Duy wrote: > The shallow repo could be deepened or shortened when then user gives s/then/the/ > --depth. But in future that won't be the only way to deepen/shorten a > repo. Stop relying on args->depth in this mode. Future deepening > methods can

Re: [PATCH v2 12/25] fetch-pack: use a common function for verbose printing

2016-02-04 Thread Eric Sunshine
On Thu, Feb 4, 2016 at 4:03 AM, Nguyễn Thái Ngọc Duy wrote: > This reduces the number of "if (verbose)" which makes it a bit easier > to read imo. It also makes it easier to redirect all these printouts, > to a file for example. > > Signed-off-by: Nguyễn Thái Ngọc Duy > --- > diff --git a/fetch-p

Re: [PATCHv8 6/9] fetching submodules: respect `submodule.fetchJobs` config option

2016-02-04 Thread Junio C Hamano
Stefan Beller writes: > diff --git a/builtin/fetch.c b/builtin/fetch.c > index 586840d..5aa1c2d 100644 > --- a/builtin/fetch.c > +++ b/builtin/fetch.c > @@ -37,7 +37,7 @@ static int prune = -1; /* unspecified */ > static int all, append, dry_run, force, keep, multiple, update_head_ok, > verbosi

Re: [PATCHv8 2/9] submodule-config: drop check against NULL

2016-02-04 Thread Jonathan Nieder
Stefan Beller wrote: > Adhere to the common coding style of Git and not check explicitly > for NULL throughout the file. There are still other occurrences in the > code base but that is usually inside of conditions with side effects. > > Signed-off-by: Stefan Beller > --- > submodule-config.c |

Re: [PATCHv8 1/9] submodule-config: keep update strategy around

2016-02-04 Thread Jonathan Nieder
Hi, It's been a while since I looked at this series. Hopefully I can come at it with some fresh eyes. Thanks for your perseverance. Stefan Beller wrote: > We need the submodule update strategies in a later patch. This description doesn't explain what the patch will do or why parse_config didn

Re: [PATCH v4 00/12] ref-filter: use parsing functions

2016-02-04 Thread Eric Sunshine
Karthik Nayak writes: > This series cleans up populate_value() in ref-filter, by moving out > the parsing part of atoms to separate parsing functions. This ensures > that parsing is only done once and also improves the modularity of the > code. > > v1: http://thread.gmane.org/gmane.comp.version-co

Re: [PATCH v4 11/12] ref-filter: introduce contents_atom_parser()

2016-02-04 Thread Eric Sunshine
On Sun, Jan 31, 2016 at 12:42 PM, Karthik Nayak wrote: > Introduce contents_atom_parser() which will parse the '%(contents)' > atom and store information into the 'used_atom' structure based on the > modifiers used along with the atom. Also introduce body_atom_parser() > and subject_atom_parser()

Re: git grep argument parser bug

2016-02-04 Thread Duy Nguyen
On Fri, Feb 5, 2016 at 5:02 AM, Dylan Grafmyre wrote: > In both ubuntu versions of git 1.9.1 and 2.7.0 > > git grep '-test' > git grep '--help' (Un)Quoting is done by shell and stripped out before "git" is executed. We just don't see them. > Or any other expressions literal leading with

Re: [PATCH v4 10/12] ref-filter: introduce remote_ref_atom_parser()

2016-02-04 Thread Eric Sunshine
On Sun, Jan 31, 2016 at 11:12:54PM +0530, Karthik Nayak wrote: > Introduce remote_ref_atom_parser() which will parse the '%(upstream)' > and '%(push)' atoms and store information into the 'used_atom' > structure based on the modifiers used along with the corresponding > atom. > > Signed-off-by: Ka

Re: [PATCH v2 13/25] fetch-pack: use a separate flag for fetch in deepening mode

2016-02-04 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > The shallow repo could be deepened or shortened when then user gives > --depth. But in future that won't be the only way to deepen/shorten a > repo. Stop relying on args->depth in this mode. Future deepening > methods can simply set this flag on instead of updating

Re: [PATCH v2 12/25] fetch-pack: use a common function for verbose printing

2016-02-04 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > This reduces the number of "if (verbose)" which makes it a bit easier > to read imo. It also makes it easier to redirect all these printouts, > to a file for example. > > Signed-off-by: Nguyễn Thái Ngọc Duy > --- > fetch-pack.c | 88 > ++

Re: [PATCH v4 09/12] ref-filter: align: introduce long-form syntax

2016-02-04 Thread Eric Sunshine
On Sun, Jan 31, 2016 at 12:42 PM, Karthik Nayak wrote: > Introduce optional prefixes "width=" and "position=" for the align atom > so that the atom can be used as "%(align:width=,position=)". > > Add Documentation and tests for the same. > > Signed-off-by: Karthik Nayak > --- > diff --git a/t/t63

Re: [PATCH v2 11/25] fetch-pack: use skip_prefix() instead of starts_with() when possible

2016-02-04 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > Signed-off-by: Nguyễn Thái Ngọc Duy > --- OK, with the same comment on "when possible". I would have reused the same "arg" without inventing a separate variable "value" if I were doing this conversion, but either way would be OK. > builtin/fetch-pack.c | 13 ++

RE: git 2.7.0 crashes when top-down memory allocation preference is set

2016-02-04 Thread Johannes Schindelin
Hi, On Thu, 4 Feb 2016, Klinger, Xia wrote: > Thanks for confirming it. I hope a fix is available soon. I am using a > very old version of Git at the moment to work around this issue, which > doesn't comply to the requirement of our Stash Git Server from > Atlassian. If you would please stop top

Re: [PATCH v4 08/12] ref-filter: introduce align_atom_parser()

2016-02-04 Thread Eric Sunshine
On Sun, Jan 31, 2016 at 12:42 PM, Karthik Nayak wrote: > Introduce align_atom_parser() which will parse an 'align' atom and > store the required alignment position and width in the 'used_atom' > structure for further usage in populate_value(). > > Since this patch removes the last usage of match_a

Re: [PATCH v2 09/25] upload-pack: tighten number parsing at "deepen" lines

2016-02-04 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > Signed-off-by: Nguyễn Thái Ngọc Duy > --- Hmm, so "deepen 10-by-the-way-let-me-tell-you-something-else" was an acceptable input that some (third-party) version of "git fetch" could have used, but now we are rejecting it. That "let me tell you something else" par

Re: [PATCH v2 08/25] upload-pack: use skip_prefix() instead of starts_with() when possible

2016-02-04 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > Signed-off-by: Nguyễn Thái Ngọc Duy > --- The result is certainly easier to read. "when possible" is not quite a right way to look at it, though. I think the patch does it when it makes sense (i.e. when the result becomes easier to read), which is much better ;

Re: [PATCH v2 07/25] upload-pack: move "unshallow" sending code out of deepen()

2016-02-04 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > Also add some more comments in this code because it takes too long to > understand what it does (to me, who should be familiar enough to > understand this code well!) > > Signed-off-by: Nguyễn Thái Ngọc Duy > --- The diff is harder to read than necessary (not you

Re: [PATCH v2 06/25] upload-pack: remove unused variable "backup"

2016-02-04 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > After the last patch, "result" and "backup" are the same. "result" used > to move, but the movement is now contained in send_shallow(). Delete > this redundant variable. > > Signed-off-by: Nguyễn Thái Ngọc Duy > --- OK. 05 and 06 squashed together would also hav

Re: [PATCH v2 04/25] upload-pack: move shallow deepen code out of receive_needs()

2016-02-04 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > This is a prep step for further refactoring. Besides reindentation and > s/shallows\./shallows->/g, no other changes are expected. > > Signed-off-by: Nguyễn Thái Ngọc Duy > --- Good. > upload-pack.c | 99 > +++---

Re: [PATCH v2 03/25] transport-helper.c: do not send null option to remote helper

2016-02-04 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > Signed-off-by: Nguyễn Thái Ngọc Duy > --- This is even more strange. Are the current callers broken and some sends value==NULL for an option that is not is_bool, resulting in a call to quote_c_style() with NULL? I somehow find it hard to believe as that would l

Re: [PATCH v2 02/25] transport-helper.c: refactor set_helper_option()

2016-02-04 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > Signed-off-by: Nguyễn Thái Ngọc Duy > --- Just like other patches, this is thin on the rationale. You are planning to invent another function that prepares the requrest in a strbuf and allow it to call this helper to perform a single round trip with the other si

Merging branches with smudge filter

2016-02-04 Thread Leonardo
Hi, everybody. I'm new to git and I'd like to keep track of some codes we have here in our company. They have some sensitive information I would like to keep private. After some googling, I found some solutions that encrypt/decrypt the files using filters as they're committed/checked out. I've been

Re: [PATCH v2 01/25] remote-curl.c: convert fetch_git() to use argv_array

2016-02-04 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > Signed-off-by: Nguyễn Thái Ngọc Duy Yay, it's about time ;-) > diff --git a/remote-curl.c b/remote-curl.c > index c704857..3ac5b6c 100644 > --- a/remote-curl.c > +++ b/remote-curl.c > @@ -726,37 +726,31 @@ static int fetch_git(struct discovery *heads, > st

Re: [PATCH v3 00/20] refs backend rebase on pu

2016-02-04 Thread David Turner
On Wed, 2016-02-03 at 21:58 -0500, Jeff King wrote: > On Thu, Feb 04, 2016 at 01:54:44AM +, Ramsay Jones wrote: > > > > They were working for me as-of the time I sent them. I guess > > > something > > > must have broken since. I'll rebase, test, and send a new > > > series. > > > > I didn't

Re: [PATCH v4 3/3] ident.c: cleanup wrt ident's source

2016-02-04 Thread Junio C Hamano
Dan Aloni writes: > +static int ident_source_is_sufficient(enum ident_source source) > +{ > + switch (source) { > + case IDENT_SOURCE_CONFIG: > + case IDENT_SOURCE_ENVIRONMENT: > + return 1; Without adding these two lines here: default: break; I

Re: [PATCH v4 06/12] ref-filter: introduce color_atom_parser()

2016-02-04 Thread Eric Sunshine
On Sun, Jan 31, 2016 at 12:42 PM, Karthik Nayak wrote: > Introduce color_atom_parser() which will parse a "color" atom and > store its color in the "used_atom" structure for further usage in > populate_value(). > > Signed-off-by: Karthik Nayak > --- > diff --git a/ref-filter.c b/ref-filter.c > @@

Re: git grep argument parser bug

2016-02-04 Thread Junio C Hamano
Dylan Grafmyre writes: > In both ubuntu versions of git 1.9.1 and 2.7.0 > > git grep '-test' > git grep '--help' > > Or any other expressions literal leading with a single dash or double > dash get interpreted as argument flags and not as search expressions. > ... > What I expect is grep

[PATCHv8 3/9] submodule-config: remove name_and_item_from_var

2016-02-04 Thread Stefan Beller
`name_and_item_from_var` does not provide the proper abstraction we need here in a later patch. As we have only a single call site for `name_and_item_from_var`, just inline it. Instead of using strbufs, use direct char *. Signed-off-by: Stefan Beller --- submodule-config.c | 40 +++--

[PATCHv8 2/9] submodule-config: drop check against NULL

2016-02-04 Thread Stefan Beller
Adhere to the common coding style of Git and not check explicitly for NULL throughout the file. There are still other occurrences in the code base but that is usually inside of conditions with side effects. Signed-off-by: Stefan Beller --- submodule-config.c | 8 1 file changed, 4 inser

[PATCHv8 1/9] submodule-config: keep update strategy around

2016-02-04 Thread Stefan Beller
We need the submodule update strategies in a later patch. Signed-off-by: Stefan Beller Signed-off-by: Junio C Hamano --- submodule-config.c | 11 +++ submodule-config.h | 1 + 2 files changed, 12 insertions(+) diff --git a/submodule-config.c b/submodule-config.c index afe0ea8..4239b0e

[PATCHv8 9/9] clone: allow an explicit argument for parallel submodule clones

2016-02-04 Thread Stefan Beller
Just pass it along to "git submodule update", which may pick reasonable defaults if you don't specify an explicit number. Signed-off-by: Stefan Beller --- Documentation/git-clone.txt | 6 +- builtin/clone.c | 19 +-- t/t7406-submodule-update.sh | 15 +

[PATCHv8 7/9] git submodule update: have a dedicated helper for cloning

2016-02-04 Thread Stefan Beller
This introduces a new helper function in git submodule--helper which takes care of cloning all submodules, which we want to parallelize eventually. Some tests (such as empty URL, update_mode=none) are required in the helper to make the decision for cloning. These checks have been moved into the C

[PATCHv8 6/9] fetching submodules: respect `submodule.fetchJobs` config option

2016-02-04 Thread Stefan Beller
This allows to configure fetching and updating in parallel without having the command line option. This moved the responsibility to determine how many parallel processes to start from builtin/fetch to submodule.c as we need a way to communicate "The user did not specify the number of parallel proc

[PATCHv8 4/9] submodule-config: slightly simplify lookup_or_create_by_name

2016-02-04 Thread Stefan Beller
No need for a strbuf, when all we use it for, is duplicating a string. Signed-off-by: Stefan Beller --- submodule-config.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/submodule-config.c b/submodule-config.c index c08ee7f..e375730 100644 --- a/submodule-config.c +++ b/

[PATCHv8 8/9] submodule update: expose parallelism to the user

2016-02-04 Thread Stefan Beller
Expose possible parallelism either via the "--jobs" CLI parameter or the "submodule.fetchJobs" setting. By having the variable initialized to -1, we make sure 0 can be passed into the parallel processing machine, which will then pick as many parallel workers as there are CPUs. Signed-off-by: Stef

[PATCHv8 0/9] Expose submodule parallelism to the user

2016-02-04 Thread Stefan Beller
This replaces sb/submodule-parallel-update. (which is based on sb/submodule-parallel-fetch, but this series also applies cleanly on master) * using a "more" correct version of parsing the section title * fixed the memleaks, free-after-use in "git submodule update: have a dedicated helper for clo

[PATCHv8 5/9] submodule-config: introduce parse_generic_submodule_config

2016-02-04 Thread Stefan Beller
This rewrites parse_config to distinguish between configs specific to one submodule and configs which apply generically to all submodules. We do not have generic submodule configs yet, but the next patch will introduce "submodule.fetchJobs". Signed-off-by: Stefan Beller --- submodule-config.c |

git grep argument parser bug

2016-02-04 Thread Dylan Grafmyre
In both ubuntu versions of git 1.9.1 and 2.7.0 git grep '-test' git grep '--help' Or any other expressions literal leading with a single dash or double dash get interpreted as argument flags and not as search expressions. What I expect is grep results for the literal strings "-test" and

Re: [PATCH 6/8] git submodule update: have a dedicated helper for cloning

2016-02-04 Thread Junio C Hamano
Stefan Beller writes: > I do not think that is a better place as not every consumer of module_list > (and module_list_compute as the nested function) will need to use the > submodule caching API. Ah, if that is the case, then OK. I was imagining that module-list may someday would return a list

Re: [PATCH v4 2/3] Add user.useConfigOnly boolean for when ident shouldn't be guessed

2016-02-04 Thread Junio C Hamano
Dan Aloni writes: > Previously, before 5498c57cdd63, many people did the following: > >git config --global user.email "(none)" > > This was helpful for people with more than one email address, > targeting different email addresses for different clones. > as it barred git from creating commit

Re: [PATCH v3 00/20] refs backend rebase on pu

2016-02-04 Thread David Turner
On Thu, 2016-02-04 at 17:09 +0700, Duy Nguyen wrote: > On Wed, Feb 3, 2016 at 3:08 AM, David Turner < > dtur...@twopensource.com> wrote: > > Are there any more reviews on this? I do have some changes from > > this > > set, but they're pretty minor so I don't want to post a new one > > (unless > >

Re: [PATCH v4 3/3] ident.c: cleanup wrt ident's source

2016-02-04 Thread Junio C Hamano
Dan Aloni writes: > * Condense the variables that tells where we got the user's >ident into single enum, instead of a collection of booleans. > * Have {committer,author}_ident_sufficiently_given directly >probe the environment and the afformentioned enum instead of >relying on git_{

Re: [PATCH v3 00/20] refs backend rebase on pu

2016-02-04 Thread David Turner
On Thu, 2016-02-04 at 20:39 +, Ramsay Jones wrote: > > On 04/02/16 20:25, David Turner wrote: > > On Thu, 2016-02-04 at 18:42 +0700, Duy Nguyen wrote: > > > On Wed, Feb 3, 2016 at 3:08 AM, David Turner < > > > dtur...@twopensource.com> wrote: > > > > Are there any more reviews on this? I do h

Re: [PATCH v3 00/20] refs backend rebase on pu

2016-02-04 Thread Ramsay Jones
On 04/02/16 20:25, David Turner wrote: > On Thu, 2016-02-04 at 18:42 +0700, Duy Nguyen wrote: >> On Wed, Feb 3, 2016 at 3:08 AM, David Turner < >> dtur...@twopensource.com> wrote: >>> Are there any more reviews on this? I do have some changes from >>> this >>> set, but they're pretty minor so I

Re: [PATCH v2 7/7] convert.c: simplify text_stat

2016-02-04 Thread Junio C Hamano
tbo...@web.de writes: > static int convert_is_binary(unsigned long size, const struct text_stat > *stats) > { > - if (stats->cr != stats->crlf) > + if (stats->lonecr) > return 1; This is an equivalent conversion, but... > @@ -266,8 +267,8 @@ static int crlf_to_git(const

Re: [PATCH v3 00/20] refs backend rebase on pu

2016-02-04 Thread David Turner
On Thu, 2016-02-04 at 18:42 +0700, Duy Nguyen wrote: > On Wed, Feb 3, 2016 at 3:08 AM, David Turner < > dtur...@twopensource.com> wrote: > > Are there any more reviews on this? I do have some changes from > > this > > set, but they're pretty minor so I don't want to post a new one > > (unless > >

Re: [PATCH 6/8] git submodule update: have a dedicated helper for cloning

2016-02-04 Thread Stefan Beller
On Wed, Feb 3, 2016 at 4:54 PM, Junio C Hamano wrote: > Stefan Beller writes: > >> On Wed, Feb 3, 2016 at 3:24 PM, Junio C Hamano wrote: >>> Stefan Beller writes: >>> + if (ce_stage(ce)) { + if (pp->recursive_prefix) + s

Re: [PATCH v2 4/7] convert.c: Use text_eol_is_crlf()

2016-02-04 Thread Junio C Hamano
tbo...@web.de writes: > From: Torsten Bögershausen > > Add a helper function to find out, which line endings > text files should get at checkout, depending on > core.autocrlf and core.eol > > Signed-off-by: Torsten Bögershausen > --- > convert.c | 25 + > 1 file changed,

Re: [PATCH v3 15/20] init: allow alternate backends to be set for new repos

2016-02-04 Thread David Turner
On Thu, 2016-02-04 at 16:48 +0700, Duy Nguyen wrote: > (picking a random series version because I didn't follow it closely) > > On Thu, Jan 14, 2016 at 11:26 PM, David Turner < > dtur...@twopensource.com> wrote: > > + if (requested_ref_storage_backend) > > + ref_storage_backend

Re: [PATCH v2 1/7] t0027: Add tests for get_stream_filter()

2016-02-04 Thread Junio C Hamano
tbo...@web.de writes: > + while test "$#" != 0 > + do > + case "$1" in > + auto)echo '*.txt text=auto' ;; > + i) echo '* ident' ;; > + text)echo '*.txt text'

Re: [PATCH 14/15] git-am.sh: replace using expr for arithmetic operations with the equivalent shell builtin

2016-02-04 Thread Stefan Beller
On which version did you base your patches? git-am.sh is no more since 2015-08-04, (it was moved to contrib/examples/git-am.sh as part of the rewrite of am in C) -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo i

Re: [PATCH 0/3] Fix $((...)) coding style

2016-02-04 Thread Junio C Hamano
Junio C Hamano writes: > One thing I was wondering about the $(( ... )) syntax while reading > this thread was about the SP around the expression, i.e. > > var=$(( $term1 * $term2 + $term3 )) > > vs > > var=$(($term1 * $term2 + $term3)) > > I personally do not have strong preference b

Re: [PATCH 0/3] Fix $((...)) coding style

2016-02-04 Thread Junio C Hamano
John Keeping writes: > I avoided quoting CodingGuidelines in my previous message, but it says: > > - Fixing style violations while working on a real change as a >preparatory clean-up step is good, but otherwise avoid useless code >churn for the sake of conforming to the style. > >"On

Re: [PATCH 14/15] git-am.sh: replace using expr for arithmetic operations with the equivalent shell builtin

2016-02-04 Thread Eric Sunshine
On Thu, Feb 4, 2016 at 2:33 PM, Junio C Hamano wrote: > As pointed out already, quoting of "$this" inside the arithmetic > expansion would not work very well, so [14/15] needs fixing. > > I do not see 01/15 thru 13/15 here, by the way. Is it just me? I didn't receive them either, and they don't

Re: [PATCH 14/15] git-am.sh: replace using expr for arithmetic operations with the equivalent shell builtin

2016-02-04 Thread Junio C Hamano
As pointed out already, quoting of "$this" inside the arithmetic expansion would not work very well, so [14/15] needs fixing. I do not see 01/15 thru 13/15 here, by the way. Is it just me? -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vge

Re: [PATCH v3 19/20] refs: add LMDB refs backend

2016-02-04 Thread David Turner
On Thu, 2016-02-04 at 16:58 +0700, Duy Nguyen wrote: > On Thu, Jan 14, 2016 at 11:26 PM, David Turner < > dtur...@twopensource.com> wrote: > > diff --git a/refs/lmdb-backend.c b/refs/lmdb-backend.c > > new file mode 100644 > > index 000..470c79f > > --- /dev/null > > +++ b/refs/lmdb-backend.c >

Re: [PATCH v3 13/20] refs: resolve symbolic refs first

2016-02-04 Thread David Turner
On Thu, 2016-02-04 at 02:37 -0500, Jeff King wrote: > On Thu, Jan 14, 2016 at 11:26:10AM -0500, David Turner wrote: > > > +static int dereference_symrefs(struct ref_transaction > > *transaction, > > + struct strbuf *err) > > +{ > > + int i; > > + int nr = transaction->

Re: COPYING tabs vs whitespaces

2016-02-04 Thread Junio C Hamano
Petr Stodulka writes: > I found that license file COPYING is different as compared with > http://www.gnu.org/licenses/gpl-2.0.txt If I pass over with > Linus's preamble, change is only about whitespaces - tabs > vs. space. Probably it's minor non-essential change, but some > projects do this cha

Re: [PATCH] git-completion.bash: always swallow error output of for-each-ref

2016-02-04 Thread Junio C Hamano
Johannes Schindelin writes: >> $ time git for-each-ref --format='%(refname:short)' refs/tags >/dev/null >> >> real0m0.009s >> user0m0.004s >> sys 0m0.004s > > And the timings in the ticket I mentioned above are not pretty small: > 0.055s vs 1.341s > >> The upcoming refname:strip does

git worktree (was: [PATCH v3 1/6] worktree: new repo extension to manage worktree behaviors)

2016-02-04 Thread Stefan Monnier
>> As a heavy user of the git-new-worktree "hack / script", is there >> something I can do to help "get more experience"? > You can try out "git worktree" command (in "lab" environment) and see > what's missing, what use cases of yours it does not support. Cool, didn't know about it, and it's even

[PATCH v2 3/7] convert.c: Remove input_crlf_action()

2016-02-04 Thread tboegi
From: Torsten Bögershausen Integrate the code of input_crlf_action() into convert_attrs(), so that ca.crlf_action is always valid after calling convert_attrs(). Keep a copy of crlf_action in attr_action, this is needed for get_convert_attr_ascii(). Remove eol_attr from struct conv_attrs, as it i

[PATCH v2 6/7] convert.c: Refactor crlf_action

2016-02-04 Thread tboegi
From: Torsten Bögershausen Refactor the determination and usage of crlf_action. Today, when no attributes are set on a file, crlf_action is set to CRLF_GUESS, and later, CRLF_GUESS is used as an indication that core.autocrlf is not false and that some automatic eol conversion is needed. Make more

[PATCH v2 5/7] convert: auto_crlf=false and no attributes set: same as binary

2016-02-04 Thread tboegi
From: Torsten Bögershausen When core.autocrlf is set to false, and no attributes are set, the file is treated as binary. Simplify the logic and remove duplicated code when dealing with (crlf_action == CRLF_GUESS && auto_crlf == AUTO_CRLF_FALSE) by setting crlf_action=CRLF_BINARY already in conver

[PATCH v2 7/7] convert.c: simplify text_stat

2016-02-04 Thread tboegi
From: Torsten Bögershausen Simplify the statistics: lonecr counts the CR which is not followed by a LF, lonelf counts the LF which is not preceded by a CR, crlf counts CRLF combinations. This simplifies the evaluation of the statistics. Signed-off-by: Torsten Bögershausen --- convert.c | 58 ++

[PATCH v2 2/7] convert.c: remove unused parameter 'path'

2016-02-04 Thread tboegi
From: Torsten Bögershausen Some functions get a parameter path, but don't use it. Remove the unused parameter. Signed-off-by: Torsten Bögershausen --- convert.c | 19 +-- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/convert.c b/convert.c index 4bb4ec1..a24c2a2

[PATCH v2 4/7] convert.c: Use text_eol_is_crlf()

2016-02-04 Thread tboegi
From: Torsten Bögershausen Add a helper function to find out, which line endings text files should get at checkout, depending on core.autocrlf and core.eol Signed-off-by: Torsten Bögershausen --- convert.c | 25 + 1 file changed, 17 insertions(+), 8 deletions(-) diff -

[PATCH v2 1/7] t0027: Add tests for get_stream_filter()

2016-02-04 Thread tboegi
From: Torsten Bögershausen When a filter is configured, a different code-path is used in convert.c and entry.c via get_stream_filter(), but there are no test cases yet. Add tests for the filter API by configuring the ident filter. The result of the SHA1 conversion is not checked, this is already

Re: parse_object does check_sha1_signature but not parse_object_buffer?

2016-02-04 Thread Junio C Hamano
Jeff King writes: > For local repository operations, most of them are about reading data. > And there I generally favor performance over extra validation, with the > caveat that we should always be aware of the tradeoff. An extra > comparison to make sure we are not going out-of-bounds on a pack

RE: git 2.7.0 crashes when top-down memory allocation preference is set

2016-02-04 Thread Klinger, Xia
Thanks for confirming it. I hope a fix is available soon. I am using a very old version of Git at the moment to work around this issue, which doesn't comply to the requirement of our Stash Git Server from Atlassian. Best regards, Xia -Original Message- From: Johannes Schindelin [mailto

Re: [PATCH 0/3] Fix $((...)) coding style

2016-02-04 Thread John Keeping
On Thu, Feb 04, 2016 at 04:27:49PM +0100, Johannes Schindelin wrote: > On Thu, 4 Feb 2016, John Keeping wrote: > > > On Thu, Feb 04, 2016 at 02:13:47PM +0100, Johannes Schindelin wrote: > > > Whatever the outcome, the inconsistency must be fixed. > > > > I disagree. Unless there are other change

RE: git 2.7.0 crashes when top-down memory allocation preference is set

2016-02-04 Thread Johannes Schindelin
Hi, On Thu, 4 Feb 2016, Klinger, Xia wrote: > I am not sure the Fast Track release means. Do you refer to Windows 10 > builds (updates)? I am running Windows 7 x64 and haven't gone to Windows > 10. The Fast Track release to which I referred is indeed Windows 10. In the meantime, I verified that

Re: [PATCH 0/3] Fix $((...)) coding style

2016-02-04 Thread Johannes Schindelin
Hi John, On Thu, 4 Feb 2016, John Keeping wrote: > On Thu, Feb 04, 2016 at 02:13:47PM +0100, Johannes Schindelin wrote: > > Whatever the outcome, the inconsistency must be fixed. > > I disagree. Unless there are other changes in the same area, the noise > isn't worth it. > > However, I do thin

Re: [PATCH 0/3] Fix $((...)) coding style

2016-02-04 Thread John Keeping
On Thu, Feb 04, 2016 at 02:13:47PM +0100, Johannes Schindelin wrote: > On Thu, 4 Feb 2016, John Keeping wrote: > > > Although I don't think the historic context is useful in deciding which > > direction to go in the future. > > Being a maintainer, I find that argument particularly hard to defend.

RE: git 2.7.0 crashes when top-down memory allocation preference is set

2016-02-04 Thread Klinger, Xia
Hi Johannes, I am not sure the Fast Track release means. Do you refer to Windows 10 builds (updates)? I am running Windows 7 x64 and haven't gone to Windows 10. Default memory allocation in Windows is bottom-up, which means the lowest addresses are consumed the first. This is all fine until the

Re: [PATCH 0/3] Fix $((...)) coding style

2016-02-04 Thread Johannes Schindelin
Hi John, On Thu, 4 Feb 2016, John Keeping wrote: > Although I don't think the historic context is useful in deciding which > direction to go in the future. Being a maintainer, I find that argument particularly hard to defend. But sure, you go ahead and prepare a patch series that turns everythi

Re: [PATCH 0/3] Fix $((...)) coding style

2016-02-04 Thread John Keeping
On Thu, Feb 04, 2016 at 01:38:51PM +0100, Johannes Schindelin wrote: > On Thu, 4 Feb 2016, John Keeping wrote: > > > Using spaces around operators also matches our C coding style. > > Well, by that reasoning you should go the whole nine yards and write > > lineno = $(( $lineno + 1 )) > >

Re: [PATCH 0/3] Fix $((...)) coding style

2016-02-04 Thread Johannes Schindelin
Hi John, On Thu, 4 Feb 2016, John Keeping wrote: > Using spaces around operators also matches our C coding style. Well, by that reasoning you should go the whole nine yards and write lineno = $(( $lineno + 1 )) Except you can't. Because shell code is inherently not like C code. What I

Re: [PATCH 0/3] Fix $((...)) coding style

2016-02-04 Thread John Keeping
On Thu, Feb 04, 2016 at 01:01:39PM +0100, Johannes Schindelin wrote: > I noticed through a nearby patch series that was submitted by Elia that > some of the $((...)) expressions introduced in scripts that I introduced > to Git's source code did not match the existing code's convention: > previously

[PATCH 3/3] rebase --merge: adjust $((...)) coding style

2016-02-04 Thread Johannes Schindelin
In 58634db (rebase: Allow merge strategies to be used when rebasing, 2006-06-21) we introduced $((...)) expressions containing spaces, disagreeing with Git's existing source code's convention. Naturally, 0bb733c (Use branch names in 'git-rebase -m' conflict hunks., 2006-12-28) repeated the convent

[PATCH 1/3] filter-branch: fix style of $((...) construct

2016-02-04 Thread Johannes Schindelin
In 6a9d16a (filter-branch: add passed/remaining seconds on progress, 2015-09-07) we introduced a new style to write $((...) expressions: with spaces in the arithmetic expression. We actually introduced *two* new styles, even: some of the $((...)) expressions had spaces after the two opening and bef

[PATCH 2/3] rebase--interactive: adjust the coding style of $((...))

2016-02-04 Thread Johannes Schindelin
In 180bad3 (rebase -i: respect core.commentchar, 2013-02-11) we changed the coding style of an arithmetic expression to introduce spaces. The existing $((...)) expression did not use that convention, though, and neither was it the habit of the other shell scripts in Git's source code. Later, 1db16

[PATCH 0/3] Fix $((...)) coding style

2016-02-04 Thread Johannes Schindelin
I noticed through a nearby patch series that was submitted by Elia that some of the $((...)) expressions introduced in scripts that I introduced to Git's source code did not match the existing code's convention: previously these expressions did not contain any spaces, now *some* do. This patch ser

Re: [PATCH 14/15] git-am.sh: replace using expr for arithmetic operations with the equivalent shell builtin

2016-02-04 Thread Johannes Schindelin
Hi Elia, On Thu, 4 Feb 2016, Elia Pinto wrote: > 2016-02-04 12:14 GMT+01:00 Johannes Schindelin : > > Hi Elia, > > > > On Thu, 4 Feb 2016, Elia Pinto wrote: > > > >> - this=$(expr "$this" + 1) > >> + this=$(( "$this" + 1 )) > > > > Why the funny spaces? We

Re: [PATCH 14/15] git-am.sh: replace using expr for arithmetic operations with the equivalent shell builtin

2016-02-04 Thread Elia Pinto
2016-02-04 12:14 GMT+01:00 Johannes Schindelin : > Hi Elia, > > On Thu, 4 Feb 2016, Elia Pinto wrote: > >> - this=$(expr "$this" + 1) >> + this=$(( "$this" + 1 )) > > Why the funny spaces? We do not do that anywhere in the existing code > except in three plac

  1   2   >