Re: [PATCH v3] http: Add Accept-Language header if possible

2014-07-13 Thread Yi, EungJun
2014-07-13 13:26 GMT+09:00 Eric Sunshine : >> + /* Decide the precision for q-factor on number of preferred >> languages. */ >> + if (num_langs + 1 > 100) { /* +1 is for '*' */ >> + q_precision = 0.001; >> + q_format = "; q=%.3f"; >> + } else if (num_l

Re: [Bug] data loss with cyclic alternates

2014-07-13 Thread Ephrim Khong
Am 11.07.14 18:01, schrieb Junio C Hamano: Ephrim Khong writes: git seems to have issues with alternates when cycles are present (repo A has B/objects as alternates, B has A/objects as alternates). Yeah, don't do that. A thinks "eh, the other guy must have it" and B thinks the same. In gen

Re: [PATCH RFC v2 03/19] rebase -i: reword executes pre-commit hook on interim commit

2014-07-13 Thread Fabian Ruch
Hi Junio, Junio C Hamano writes: > Fabian Ruch writes: >> The to-do list command `reword` replays a commit like `pick` but lets >> the user also edit the commit's log message. This happens in two >> steps. Firstly, the named commit is cherry-picked. Secondly, the >> commit created in the first st

Re: [PATCH 3/4 v6] cache-tree: subdirectory tests

2014-07-13 Thread Junio C Hamano
David Turner writes: > On Fri, 2014-07-11 at 08:40 -0700, Junio C Hamano wrote: > >> In the ideal world, I think whoever tries to compare two cache-trees >> (i.e. test-dump-cache-tree) should *not* care, because we are merely >> trying to show what the correct tree object name for the node would

Re: [PATCH v3] http: Add Accept-Language header if possible

2014-07-13 Thread Junio C Hamano
"Yi, EungJun" writes: > I think it is possible like this: > > num_langs += 1; /* for '*' */ > decimal_places = 1 + (num_langs > 10) + (num_langs > 100); > snprintf(q_format, sizeof(q_format), "; q=%%.%df", decimal_places); > for (q_precision = 1.0; decimal_places-- > 0;) q_precisi

Re: [PATCH 3/3 v5] tag: support configuring --sort via .gitconfig

2014-07-13 Thread Junio C Hamano
Jeff King writes: > On Fri, Jul 11, 2014 at 02:54:25PM -0700, Junio C Hamano wrote: > >> > Yeah, we're quite inconsistent there. In some cases we silently ignore >> > something unknown (e.g., a color.diff.* slot that we do not understand), >> > but in most cases if it is a config key we understan

Re: [PATCH 3/3] tag: support configuring --sort via .gitconfig

2014-07-13 Thread Junio C Hamano
Eric Sunshine writes: >> Made parse_sort_string take a "var" parameter, and if given will only warn >> about invalid parameter, instead of error. > > This seems unnecessarily ugly since it's hard-coding specialized > knowledge of the callers' error-reporting requirements into what > should be a g

Re: [PATCH v7 4/4] cache-tree: Write updated cache-tree after commit

2014-07-13 Thread Junio C Hamano
Eric Sunshine writes: >> + (echo p; echo 1; echo; echo s; echo n; echo y; echo q) | git commit >> --interactive -m foo > > Broken &&-chain. > > Would a printf make this more readable? > > printf "p\n1\n\ns\nn\ny\nq\n" | git commt ... && > > Perhaps not. But printf "%s\n" p 1

Re: [PATCH 3/3] tag: support configuring --sort via .gitconfig

2014-07-13 Thread Jeff King
On Sun, Jul 13, 2014 at 10:10:27AM -0700, Junio C Hamano wrote: > Eric Sunshine writes: > > >> Made parse_sort_string take a "var" parameter, and if given will only warn > >> about invalid parameter, instead of error. > > > > This seems unnecessarily ugly since it's hard-coding specialized > > k

Re: [PATCH 3/3] tag: support configuring --sort via .gitconfig

2014-07-13 Thread Jeff King
On Sun, Jul 13, 2014 at 01:33:56PM -0400, Jeff King wrote: > I realize that I am reinventing the error-reporting wheel on a sleepy > Sunday afternoon without having thought about it much, so there is > probably some gotcha or case that makes this ugly, or perhaps it just > ends up verbose in pract

Re: [PATCH v7 4/4] cache-tree: Write updated cache-tree after commit

2014-07-13 Thread Eric Sunshine
On Sun, Jul 13, 2014 at 1:22 PM, Junio C Hamano wrote: > Eric Sunshine writes: > >>> + (echo p; echo 1; echo; echo s; echo n; echo y; echo q) | git commit >>> --interactive -m foo >> >> Broken &&-chain. >> >> Would a printf make this more readable? >> >> printf "p\n1\n\ns\nn\ny\nq\n" |

Re: [PATCH 2/7] move setting of object->type to alloc_* functions

2014-07-13 Thread Ramsay Jones
On 13/07/14 07:41, Jeff King wrote: > On Sat, Jul 12, 2014 at 02:05:39PM -0400, Jeff King wrote: > >>> I don't particularly like 'flag' here. (not a massive dislike, mind you:) >>> >>> Perhaps: flag->object_type, type->node_type? >>> Or, if that's too verbose, maybe just: flag->type, type->node? >

[PATCH v9 2/4] test-dump-cache-tree: invalid trees are not errors

2014-07-13 Thread David Turner
From: David Turner Do not treat known-invalid trees as errors even when their subtree_nr is incorrect. Because git already knows that these trees are invalid, an incorrect subtree_nr will not cause problems. Add a couple of comments. Signed-off-by: David Turner --- test-dump-cache-tree.c | 4

[PATCH v9 1/4] cache-tree: Create/update cache-tree on checkout

2014-07-13 Thread David Turner
From: David Turner When git checkout checks out a branch, create or update the cache-tree so that subsequent operations are faster. update_main_cache_tree learned a new flag, WRITE_TREE_REPAIR. When WRITE_TREE_REPAIR is set, portions of the cache-tree which do not correspond to existing tree ob

[PATCH v9 4/4] cache-tree: Write updated cache-tree after commit

2014-07-13 Thread David Turner
From: David Turner During the commit process, update the cache-tree. Write this updated cache-tree so that it's ready for subsequent commands. Add test code which demonstrates that git commit now writes the cache tree. Make all tests test the entire cache-tree, not just the root level. Signed-

[PATCH v9 3/4] cache-tree: subdirectory tests

2014-07-13 Thread David Turner
From: David Turner Add tests to confirm that invalidation of subdirectories neither over- nor under-invalidates. Signed-off-by: David Turner --- t/t0090-cache-tree.sh | 26 +++--- 1 file changed, 23 insertions(+), 3 deletions(-) diff --git a/t/t0090-cache-tree.sh b/t/t0090

Re: [PATCH v3] http: Add Accept-Language header if possible

2014-07-13 Thread Yi, EungJun
2014-07-14 1:57 GMT+09:00 Junio C Hamano : > > If you do not want floating point (and I think we tend to avoid it > when we do not need it), you can realize that in your use of "0.1" > and "0.01" and "0.001" there is nothing fundamentally floating-point; > you can measure how many digits below the

Re: [PATCH 00/14] Add submodule test harness

2014-07-13 Thread Junio C Hamano
Jens Lehmann writes: >> Perhaps squashing this to 7e8e5af9 instead? > > Yes please, this is much better than my first attempt. One thing that I found troubling is the ../../../ "three levels up" is hardcoded. Would it be always true for any value of "$1"? If the submodule is bound to the super

Kindly reply

2014-07-13 Thread Carlos Ramirez
My name is Carlos Ramirez, I am lawyer here in Madrid Spain. I want to transfer an abandoned sum of 13.5 Millions USD to your account.50% will be for you. No risk involved. Contact me for more details. Kindly reply me back to my alternative email address ( carlos...@aol.com ) Regards Car

Re: Race condition in git push --mirror can cause silent ref rewinding

2014-07-13 Thread Alex Vandiver
On 07/02/2014 07:10 PM, Alex Vandiver wrote: > On 07/02/2014 06:20 PM, Junio C Hamano wrote: >> Alex Vandiver writes: >> >>> [remote "github"] >>> url = g...@github.com:bestpractical/rt.git >>> fetch = +refs/*:refs/* >>> mirror = yes >> >> "git push github master^:maste

Re: [PATCH 2/2] dir: remove PATH_MAX limitation

2014-07-13 Thread Junio C Hamano
Duy Nguyen writes: >> [01/20] dir.c: coding style fix >> [02/20] dir.h: move struct exclude declaration to top level >> [03/20] prep_exclude: remove the artificial PATH_MAX limit >> >> ...perhaps with s/if (!dir->basebuf.alloc)/if (!dir->basebuf.buf)/ >> >> @Duy any reason for not signing off tha

Kindly reply

2014-07-13 Thread Carlos Ramirez
My name is Carlos Ramirez, I am lawyer here in Madrid Spain. I want to transfer an abandoned sum of 13.5 Millions USD to your account.50% will be for you. No risk involved. Contact me for more details. Kindly reply me back to my alternative email address ( carlos...@aol.com ) Regards Car

Re: [PATCH v6 28/32] gc: style change -- no SP before closing bracket

2014-07-13 Thread Junio C Hamano
On Wed, Jul 9, 2014 at 2:47 AM, Eric Sunshine wrote: > On Wed, Jul 9, 2014 at 3:33 AM, Nguyễn Thái Ngọc Duy > wrote: > > Yet, there is a space after the opening '{'. So, this is now > inconsistently formatted as: > > { foo, bar} > So, if we drop the other hunk and keep only the one below, t

Re: [PATCH v7 00/31] Support multiple checkouts

2014-07-13 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > fd = open(git_path("repos/%s/gitdir", id), O_RDONLY); > ... > - while (path[len - 1] == '\n' || path[len - 1] == '\r') > + while (len && (path[len - 1] == '\n' || path[len - 1] == '\r')) > len--; Do we anticipate (or even allow/endorse)

[PATCH/RFH 0/3] stable priority-queue

2014-07-13 Thread Jeff King
As Junio and I discussed earlier in [1], this series makes the prio_queue struct stable with respect to object insertion (which in turn means we can use it to replace commit_list in more places). I think everything here is correct, but the second commit fails the final test in t5539. I think the t

[PATCH 1/3] prio-queue: factor out compare and swap operations

2014-07-13 Thread Jeff King
When manipulating the priority queue's heap, we frequently have to compare and swap heap entries. As we are storing only void pointers right now, this is quite easy to do inline in a few lines. However, when we start using a more complicated heap entry in a future patch, that will get longer. Facto

[PATCH 2/3] prio-queue: make output stable with respect to insertion

2014-07-13 Thread Jeff King
If two items are added to a prio_queue and compare equal, they currently come out in an apparently random order (this order is deterministic for a particular sequence of insertions and removals, but does not necessarily match the insertion order). This makes it unlike using a date-ordered commit_li

[PATCH 3/3] paint_down_to_common: use prio_queue

2014-07-13 Thread Jeff King
When we are traversing to find merge bases, we keep our usual commit_list of commits to process, sorted by their commit timestamp. As we add each parent to the list, we have to spend "O(width of history)" to do the insertion, where the width of history is the number of simultaneous lines of develop

Re: [PATCH 2/7] move setting of object->type to alloc_* functions

2014-07-13 Thread Jeff King
On Sun, Jul 13, 2014 at 08:27:51PM +0100, Ramsay Jones wrote: > > Thinking on this more, writing out the definitions is the only sane > > thing to do here, now that alloc_commit_node does not use the macro. > > Otherwise you are inviting people to modify the macro, but fail to > > notice that the

Re: 745224e0 gcc-4.9 emmintrin.h build error

2014-07-13 Thread Jeff King
On Sat, Jul 12, 2014 at 10:47:03AM +0200, Tuncer Ayaz wrote: > Yes, Andi's patch works. > > Any idea when ak/profile-feedback-build will land in master? Junio posts updates in his "What's Cooking" messages (usually about twice a week). Last Tuesday's listed it as "will merge to next". Unless an

Re: 745224e0 gcc-4.9 emmintrin.h build error

2014-07-13 Thread Jeff King
On Sat, Jul 12, 2014 at 10:53:47AM +0200, Tuncer Ayaz wrote: > On Sat, Jul 12, 2014 at 6:56 AM, Jeff King wrote: > > > I think none of the regular devs uses PROFILE, and it bit-rotted > > By the way, is there no build (CI) server for git.git to regularly > test branches on different platforms or