Re: How to handle patch series conflicts

2018-10-07 Thread Stephen & Linda Smith
On Wednesday, September 5, 2018 2:16:06 PM MST Junio C Hamano wrote: > Stephen & Linda Smith writes: > > Junio - > > > > On Tuesday, September 4, 2018 10:27:26 AM MST Junio C Hamano wrote: > >> > t7500-commit.sh > >> > t7501-commit.sh > >> > t7502-commit.sh > >> > t7509-commit.sh > >> > >>

Re: What's so special about objects/17/ ?

2018-10-07 Thread Junio C Hamano
Johannes Sixt writes: > Am 07.10.18 um 21:06 schrieb Ævar Arnfjörð Bjarmason: >> Picking any one number is explained in the comment. I'm asking why 17 in >> particular not for correctness reasons but as a bit of historical lore, >> and because my ulterior is to improve the GC docs. >> >> The

Re: What's so special about objects/17/ ?

2018-10-07 Thread Johannes Sixt
Am 07.10.18 um 21:06 schrieb Ævar Arnfjörð Bjarmason: Picking any one number is explained in the comment. I'm asking why 17 in particular not for correctness reasons but as a bit of historical lore, and because my ulterior is to improve the GC docs. The number in that comic is 4 (and no

Re: [PATCH 00/15] sequencer: refactor functions working on a todo_list

2018-10-07 Thread Alban Gruin
Le 07/10/2018 à 21:54, Alban Gruin a écrit : > At the center of the "interactive" part of the interactive rebase lies > the todo list. When the user starts an interactive rebase, a todo list > is generated, presented to the user (who then edits it using a text > editor), read back, and then is

I am still waiting for your reply to my letter to you, Get back to me so that I can give you more details.

2018-10-07 Thread Sindiy Abiu

Re: What's so special about objects/17/ ?

2018-10-07 Thread Junio C Hamano
Junio C Hamano writes: > Ævar Arnfjörð Bjarmason writes: > >> 1. We still have this check of objects/17/ in builtin/gc.c today. Why >>objects/17/ and not e.g. objects/00/ to go with other 000* magic such >>as the SHA-1?d Statistically >>it

[PATCH 07/15] sequencer: make sequencer_make_script() write its script to a strbuf

2018-10-07 Thread Alban Gruin
This makes sequencer_make_script() write its script to a strbuf (ie. the buffer of a todo_list) instead of a FILE. This reduce the amount of read/write made by rebase interactive. Signed-off-by: Alban Gruin --- builtin/rebase--interactive.c | 13 +++- sequencer.c | 38

[PATCH 06/15] sequencer: refactor transform_todos() to work on a todo_list

2018-10-07 Thread Alban Gruin
This refactors transform_todos() to work on a todo_list. The function is renamed todo_list_transform(). As rebase -p still need to check the todo list from the disk, a new function is introduced, transform_todo_file(). todo_list_transform() is not a static function, because it will be used by

[PATCH 15/15] rebase--interactive: move transform_todo_file() to rebase--interactive.c

2018-10-07 Thread Alban Gruin
As transform_todo_file() is only needed inside of rebase--interactive.c, it is moved there from sequencer.c. Signed-off-by: Alban Gruin --- builtin/rebase--interactive.c | 21 + sequencer.c | 21 - sequencer.h | 1 - 3

[PATCH 08/15] sequencer: change complete_action() to use the refactored functions

2018-10-07 Thread Alban Gruin
complete_action() used functions that read the todo-list file, made some changes to it, and wrote it back to the disk. The previous commits were dedicated to separate the part that deals with the file from the actual logic of these functions. Now that this is done, we can call directly the

[PATCH 03/15] sequencer: refactor check_todo_list() to work on a todo_list

2018-10-07 Thread Alban Gruin
This refactors check_todo_list() to work on a todo_list to avoid redundant reads and writes to the disk. The function is renamed todo_list_check(). As rebase -p still need to check the todo list from the disk, a new function is introduced, check_todo_list_from_file(). It reads the file from the

[PATCH 09/15] sequencer: refactor skip_unnecessary_picks() to work on a todo_list

2018-10-07 Thread Alban Gruin
This refactors skip_unnecessary_picks() to work on a todo_list. The file-handling logic is completely dropped here, as its only usage is made by complete_action(). Signed-off-by: Alban Gruin --- sequencer.c | 56 +++-- 1 file changed, 16

[PATCH 02/15] sequencer: make the todo_list structure public

2018-10-07 Thread Alban Gruin
This makes the structures todo_list and todo_item, and the functions todo_list_release() and parse_insn_buffer(), accessible outside of sequencer.c. Signed-off-by: Alban Gruin --- sequencer.c | 66 + sequencer.h | 48

[PATCH 10/15] rebase-interactive: use todo_list_transform() in edit_todo_list()

2018-10-07 Thread Alban Gruin
Just like complete_action(), edit_todo_list() used a function (transform_todo_file()) that read the todo-list from the disk and wrote it back, resulting in useless disk accesses. This changes edit_todo_list() to call directly todo_list_transform() instead. Signed-off-by: Alban Gruin ---

[PATCH 01/15] sequencer: clear the number of items of a todo_list before parsing

2018-10-07 Thread Alban Gruin
This clears the number of items of a todo_list before parsing it to allow to parse the same list multiple times without issues. As its items are not dynamically allocated, or don’t need to allocate memory, no additionnal memory management is required here. Signed-off-by: Alban Gruin ---

[PATCH 14/15] sequencer: fix a call to error() in transform_todo_file()

2018-10-07 Thread Alban Gruin
This replaces a call to error() by a call to error_errno() after writing the content of the todo list to the disk in transform_todo_file(). Signed-off-by: Alban Gruin --- sequencer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sequencer.c b/sequencer.c index

[PATCH 00/15] sequencer: refactor functions working on a todo_list

2018-10-07 Thread Alban Gruin
At the center of the "interactive" part of the interactive rebase lies the todo list. When the user starts an interactive rebase, a todo list is generated, presented to the user (who then edits it using a text editor), read back, and then is checked and processed before the actual rebase takes

[PATCH 11/15] rebase-interactive: append_todo_help() changes

2018-10-07 Thread Alban Gruin
This moves the writing of the comment "Rebase $shortrevisions onto $shortonto ($command_count commands)" from complete_action() to append_todo_help(). shortrevisions, shortonto, and command_count are passed as parameters to append_todo_help(). During the initial edit of the todo list,

[PATCH 04/15] sequencer: refactor sequencer_add_exec_commands() to work on a todo_list

2018-10-07 Thread Alban Gruin
This refactors sequencer_add_exec_commands() to work on a todo_list to avoid redundant reads and writes to the disk. sequencer_add_exec_commands() still reads the todo list from the disk, as it is needed by rebase -p. todo_list_add_exec_commands() works on a todo_list structure, and reparses it

[PATCH 05/15] sequencer: refactor rearrange_squash() to work on a todo_list

2018-10-07 Thread Alban Gruin
This refactors rearrange_squash() to work on a todo_list to avoid redundant reads and writes. The function is renamed todo_list_rearrange_squash(). As rebase -p still need to check the todo list from the disk, a new function is introduced, rearrange_squash_in_todo_file(). Signed-off-by: Alban

[PATCH 13/15] sequencer: use edit_todo_list() in complete_action()

2018-10-07 Thread Alban Gruin
This changes complete_action() to use edit_todo_list(), now that it can handle the initial edit of the todo list. Signed-off-by: Alban Gruin --- sequencer.c | 27 +++ 1 file changed, 7 insertions(+), 20 deletions(-) diff --git a/sequencer.c b/sequencer.c index

[PATCH 12/15] rebase-interactive: rewrite edit_todo_list() to handle the initial edit

2018-10-07 Thread Alban Gruin
edit_todo_list() is changed to work on a todo_list, and to handle the initial edition of the todo list (ie. making a backup of the todo list). It does not check for dropped commits yet, as todo_list_check() does not work if the old todo list has invalid commands. Signed-off-by: Alban Gruin ---

Re: What's so special about objects/17/ ?

2018-10-07 Thread Junio C Hamano
Ævar Arnfjörð Bjarmason writes: > 1. We still have this check of objects/17/ in builtin/gc.c today. Why >objects/17/ and not e.g. objects/00/ to go with other 000* magic such >as the SHA-1?d Statistically >it doesn't matter, but 17 seems like

Re: What's so special about objects/17/ ?

2018-10-07 Thread Ævar Arnfjörð Bjarmason
On Sun, Oct 07 2018, Johannes Sixt wrote: > Am 07.10.18 um 20:28 schrieb Ævar Arnfjörð Bjarmason: >> In 2007 Junio wrote >> (https://public-inbox.org/git/7vr6lcj2zi@gitster.siamese.dyndns.org/): >> >> +static int need_to_gc(void) >> +{ >> + /* >> +* Quickly

Re: What's so special about objects/17/ ?

2018-10-07 Thread Johannes Sixt
Am 07.10.18 um 20:28 schrieb Ævar Arnfjörð Bjarmason: In 2007 Junio wrote (https://public-inbox.org/git/7vr6lcj2zi@gitster.siamese.dyndns.org/): +static int need_to_gc(void) +{ + /* + * Quickly check if a "gc" is needed, by estimating how + * many loose objects

What's so special about objects/17/ ?

2018-10-07 Thread Ævar Arnfjörð Bjarmason
In 2007 Junio wrote (https://public-inbox.org/git/7vr6lcj2zi@gitster.siamese.dyndns.org/): +static int need_to_gc(void) +{ + /* +* Quickly check if a "gc" is needed, by estimating how +* many loose objects there are. Because SHA-1 is evenly +*

Diff Range Underflow

2018-10-07 Thread Era
I discovered an apparent underflow when using the —unified=0 / -U0 flag with git-show on a merge commit. Leaving the flag on its default value or 1 shows the ranges correctly. $git --no-pager show -z --no-color --pretty=%x00%s%x00%b%x00 -U1 3ac9cfed9ce01836dea1fee96c4eceb2df4b6878

Re: [PATCH v3] coccicheck: process every source file at once

2018-10-07 Thread Beat Bolli
On 07.10.18 13:36, Beat Bolli wrote: > On 02.10.18 22:18, Jacob Keller wrote: >> On Tue, Oct 2, 2018 at 1:07 PM Jacob Keller wrote: >>> >>> From: Jacob Keller >>> >>> make coccicheck is used in order to apply coccinelle semantic patches, >>> and see if any of the transformations found within

Re: [PATCH v3] coccicheck: process every source file at once

2018-10-07 Thread Beat Bolli
On 02.10.18 22:18, Jacob Keller wrote: > On Tue, Oct 2, 2018 at 1:07 PM Jacob Keller wrote: >> >> From: Jacob Keller >> >> make coccicheck is used in order to apply coccinelle semantic patches, >> and see if any of the transformations found within contrib/coccinelle/ >> can be applied to the

[PATCH 1/1] subtree: add build targets 'man' and 'html'

2018-10-07 Thread Christian Hesse
From: Christian Hesse We have targets 'install-man' and 'install-html', let's add build targets as well. Signed-off-by: Christian Hesse --- contrib/subtree/Makefile | 4 1 file changed, 4 insertions(+) diff --git a/contrib/subtree/Makefile b/contrib/subtree/Makefile index