[PATCH v3 6/6] bisect: allows any terms set by user

2015-06-22 Thread Antoine Delaite
Introduction of the git bisect terms function. The user can set its own terms. It will work exactly like before. The terms must be set before the start. Signed-off-by: Antoine Delaite Signed-off-by: Louis Stuber --- Documentation/git-bisect.txt | 19 git-bisect.sh

[PATCH v3 5/6] revision: fix rev-list --bisect in old/new mode

2015-06-22 Thread Antoine Delaite
) now). Signed-off-by: Louis Stuber Signed-off-by: Antoine Delaite --- revision.c | 16 ++-- 1 files changed, 14 insertions(+), 2 deletions(-) diff --git a/revision.c b/revision.c index 3ff8723..27750ac 100644 --- a/revision.c +++ b/revision.c @@ -21,6 +21,9 @@ volatile

[PATCH v3 4/6] bisect: add the terms old/new

2015-06-22 Thread Antoine Delaite
( v2 1/7-4/7 ) - http://comments.gmane.org/gmane.comp.version-control.git/271343 ( v2 5/7-7/7 ) Signed-off-by: Antoine Delaite Signed-off-by: Louis Stuber Signed-off-by: Valentin Duperray Signed-off-by: Franck Jonas Signed-off-by: Lucien Kong Signed-off-by: Thomas Nguy Sign

[PATCH v3 3/6] bisect: simplify the addition of new bisect terms

2015-06-22 Thread Antoine Delaite
We create a file BISECT_TERMS in the repository .git to be read during a bisection. The fonctions to be changed if we add new terms are quite few. In git-bisect.sh : check_and_set_terms bisect_voc Signed-off-by: Antoine Delaite Signed-off-by: Louis Stuber Signed-off-by: Valentin

[PATCH v3 2/6] bisect: replace hardcoded "bad|good" by variables

2015-06-22 Thread Antoine Delaite
To add new tags like old/new and have keywords less confusing, the first step is to avoid hardcoding the keywords. The default mode is still bad/good. Signed-off-by: Antoine Delaite Signed-off-by: Louis Stuber Signed-off-by: Valentin Duperray Signed-off-by: Franck Jonas Signed-off-by: Lucien

[PATCH v3 1/6] bisect: correction of typo

2015-06-22 Thread Antoine Delaite
Signed-off-by: Antoine Delaite --- bisect.c|2 +- t/t6030-bisect-porcelain.sh |2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bisect.c b/bisect.c index 03d5cd9..5b8357d 100644 --- a/bisect.c +++ b/bisect.c @@ -743,7 +743,7 @@ static void

[PATCH v2 2/7] bisect: replace hardcoded "bad|good" by variables

2015-06-22 Thread Antoine Delaite
Matthieu Moy wrote: >Being an acceptable ref name is a constraint you have to check (Junio >already mentionned check-ref-format). I think quoting variables makes >sense too I don't get how 'git check-ref-format' works exactly. It says it needs at least one slash in the ref name. So it would

[PATCH v2 7/7] bisect: allows any terms set by user

2015-06-17 Thread Antoine Delaite
Matthieu Moy writes: >> >>># terms_defined is 0 when the user did not define the terms explicitely >>># yet. This is the case when running 'git bisect start bad_rev good_rev' >>># before we see an explicit reference to a term. >>>terms_defined=0 >> >> The thing is: >> 'git bisect reset >

[PATCH v2 7/7] bisect: allows any terms set by user

2015-06-16 Thread Antoine Delaite
Matthieu Moy writes: ># terms_defined is 0 when the user did not define the terms explicitely ># yet. This is the case when running 'git bisect start bad_rev good_rev' ># before we see an explicit reference to a term. >terms_defined=0 The thing is: 'git bisect reset git bisect new HEAD (autostar

[PATCH v2 7/7] bisect: allows any terms set by user

2015-06-16 Thread Antoine Delaite
Matthieu Moy writes: >I would say "for the current bisection", i.e. > >$ git bisect start >$ git bisect terms foo bar # Scope starts here >... >The first 'bar' commit is deadbeef. # Scope ends here > >$ git bisect terms foo bar >You need to start by "git bisect start" >Do you want me to

[PATCH v2 7/7] bisect: allows any terms set by user

2015-06-14 Thread Antoine Delaite
This message's goal is to explained where am I on the bisect functions. -git bisect replay now work with any terms. -I took account of most of the last reviews (coding style, double sed ...) -'git bisect terms' without arguments now display the current terms -bisect_terms : if a bisection ha

[PATCH v2 7/7] bisect: allows any terms set by user

2015-06-14 Thread Antoine Delaite
Matthieu Moy writes: >> +if test -s "$GIT_DIR/TERMS_DEFINED" >> +then >> +terms_defined=1 >> +get_terms >> +rm -rf "$GIT_DIR/TERMS_DEFINED" > >I don't understand why you need to delete this file. I did not review >thoroughly so there

[PATCH v2 7/7] bisect: allows any terms set by user

2015-06-14 Thread Antoine Delaite
Louis Stuber writes: >Matthieu Moy writes: > >> Modifying in PATCH 7 some code that you introduced in PATCH 3 is >> suspicious. Is there any reason you did not name the variable >> "terms_defined" in the first place? (i.e. squash this hunk and the other >> instance of start_bad_good into P

[PATCH v2 6/7] revision: fix rev-list --bisect in old/new mode

2015-06-10 Thread Antoine Delaite
) now). Signed-off-by: Louis Stuber Signed-off-by: Antoine Delaite --- revision.c | 16 ++-- 1 files changed, 14 insertions(+), 2 deletions(-) diff --git a/revision.c b/revision.c index 7ddbaa0..a332270 100644 --- a/revision.c +++ b/revision.c @@ -21,6 +21,9 @@ volatile

[PATCH v2 7/7] bisect: allows any terms set by user

2015-06-10 Thread Antoine Delaite
Introduction of the git bisect terms function. The user can set its own terms. List of known commands not available : `git bisect replay` `git bisect terms term1 term2 then git bisect start bad_rev good_rev` Signed-off-by: Antoine Delaite Signed-off-by: Louis Stuber --- Documentation/git

[PATCH v2 5/7] bisect: change read_bisect_terms parameters

2015-06-10 Thread Antoine Delaite
From: Louis Stuber The function reads BISECT_TERMS and stores it at the adress given in parameters (instead of global variables name_bad and name_good). This allows to use the function outside bisect.c. Signed-off-by: Antoine Delaite Signed-off-by: Louis Stuber --- bisect.c | 15

[PATCH v2 4/7] bisect: add the terms old/new

2015-06-10 Thread Antoine Delaite
ane.comp.version-control.git/182398 discussion around bisect yes/no or old/new. - http://thread.gmane.org/gmane.comp.version-control.git/199758 last discussion and reviews Signed-off-by: Antoine Delaite Signed-off-by: Louis Stuber Signed-off-by: Valentin Du

[PATCH v2 2/7] bisect: replace hardcoded "bad|good" by variables

2015-06-10 Thread Antoine Delaite
To add new tags like old/new and have keywords less confusing, the first step is to avoid hardcoding the keywords. The default mode is still bad/good. Signed-off-by: Antoine Delaite Signed-off-by: Louis Stuber Signed-off-by: Valentin Duperray Signed-off-by: Franck Jonas Signed-off-by: Lucien

[PATCH v2 3/7] bisect: simplify the addition of new bisect terms

2015-06-10 Thread Antoine Delaite
We create a file BISECT_TERMS in the repository .git to be read during a bisection. The fonctions to be changed if we add new terms are quite few. In git-bisect.sh : check_and_set_terms bisect_voc In bisect.c : handle_bad_merge_base Signed-off-by: Antoine Delaite Signed

[PATCH v2 1/7] bisect : correction of typo

2015-06-10 Thread Antoine Delaite
Signed-off-by: Antoine Delaite --- bisect.c|2 +- t/t6030-bisect-porcelain.sh |2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bisect.c b/bisect.c index 10f5e57..de92953 100644 --- a/bisect.c +++ b/bisect.c @@ -743,7 +743,7 @@ static void

[PATCH 4/4] bisect: add the terms old/new

2015-06-10 Thread Antoine Delaite
Hi, thanks for the review, (sorry if you received this twice) Junio C Hamano writes: >Just throwing a suggestion. You could perhaps add a new verb to be >used before starting to do anything, e.g. > > $ git bisect terms new old Yes it would be nice and should not be hard to implement. B

[PATCH 2/4] bisect: replace hardcoded "bad|good" by variables

2015-06-10 Thread Antoine Delaite
Hi, Thanks for the review, (sorry if you received this twice) Matthieu Moy wrote: >> +static const char *name_bad; >> +static const char *name_good; > >Same remark as PATCH 2. After the discussion you had with Christian I think we will keep name_bad/good for now. >> - >> - fprintf(s

[PATCH 3/4] bisect: simplify the add of new bisect terms

2015-06-10 Thread Antoine Delaite
Hi, Thanks for the review ! (sorry if you received this twice) Christian Couder wrote : >>> + name_bad = "bad"; >>> + name_good = "good"; >>> + } else { >>> + strbuf_getline(&str, fp, '\n'); >>> + name_bad = strbuf_detach(&str, NULL); >>> + strbuf_getline(&str, fp, '\n'); >>> + name_go

Re: [PATCH 3/4] bisect: simplify the add of new bisect terms

2015-06-09 Thread Antoine Delaite
Hi, Thanks for the review, Junio C Hamano writes: >> /* >> + * The terms used for this bisect session are stocked in >> + * BISECT_TERMS: it can be bad/good or new/old. >> + * We read them and stock them to adapt the messages >> + * accordingly. Default is bad/good. >> + */ > >s/stock/store/ p

[PATCH 4/4] bisect: add the terms old/new

2015-06-08 Thread Antoine Delaite
ane.comp.version-control.git/182398 discussion around bisect yes/no or old/new. - http://thread.gmane.org/gmane.comp.version-control.git/199758 last discussion and reviews Signed-off-by: Antoine Delaite Signed-off-by: Louis Stuber Signed-off-by: Valentin Du

[PATCH 1/4] bisect : correction of typo

2015-06-08 Thread Antoine Delaite
--- bisect.c| 2 +- t/t6030-bisect-porcelain.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bisect.c b/bisect.c index 10f5e57..de92953 100644 --- a/bisect.c +++ b/bisect.c @@ -743,7 +743,7 @@ static void handle_bad_merge_base(void) fprintf(s

[PATCH 3/4] bisect: simplify the add of new bisect terms

2015-06-08 Thread Antoine Delaite
We create a file BISECT_TERMS in the repository .git to be read during a bisection. The fonctions to be changed if we add new terms are quite few. In git-bisect.sh : check_and_set_terms bisect_voc In bisect.c : handle_bad_merge_base Signed-off-by: Antoine Delaite Signed

[PATCH 2/4] bisect: replace hardcoded "bad|good" by variables

2015-06-08 Thread Antoine Delaite
To add new tags like old/new and have keywords less confusing, the first step is to avoid hardcoding the keywords. The default mode is still bad/good. Signed-off-by: Antoine Delaite Signed-off-by: Louis Stuber Signed-off-by: Valentin Duperray Signed-off-by: Franck Jonas Signed-off-by: Lucien

[PATCH 2/3] bisect: use name_(bad|good) instead of bisect_(bad|good)

2015-06-04 Thread Antoine Delaite
From: Christian Couder Signed-off-by: Antoine Delaite --- bisect.c | 35 +-- 1 file changed, 17 insertions(+), 18 deletions(-) diff --git a/bisect.c b/bisect.c index d6c19fd..68417bb 100644 --- a/bisect.c +++ b/bisect.c @@ -21,8 +21,8 @@ static const char

[WIP PATCH 1/3] git bisect old/new

2015-06-04 Thread Antoine Delaite
unfixed to find fix. - http://thread.gmane.org/gmane.comp.version-control.git/182398 discussion around bisect yes/no or old/new. - http://thread.gmane.org/gmane.comp.version-control.git/199758 last discussion and reviews Signed-off-by: Antoine Delaite Sign

[PATCH 3/3] bisect: fix indentation

2015-06-04 Thread Antoine Delaite
From: Christian Couder Signed-off-by: Antoine Delaite --- bisect.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/bisect.c b/bisect.c index 68417bb..87a5f6d 100644 --- a/bisect.c +++ b/bisect.c @@ -915,10 +915,10 @@ void read_bisect_terms(void

GIT BISECT old/new (fix/unfixed)

2015-06-01 Thread Antoine Delaite
Hi, git bisect old/new is an alternative to good/bad, which can be confusing to use in some situations. A work on it was done a few years ago, it is partially working but there are a lot of issues. We based on Christian Couder's github: https://github.com/chriscool/git/commits/boldnew2 We