[PATCH v3 1/3] t4202: refactor test

2016-06-24 Thread Mehul Jain
that tests added by subsequent patches reuse the 'signed' branch in the same way. Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t4202-log.sh | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/t/t4202-log.sh b/t/t4202-log.sh index 128ba93..ab66ee0

Re: [PATCH v3 0/3] Introduce log.showSignature config variable

2016-06-24 Thread Mehul Jain
On Thu, Jun 23, 2016 at 12:02 PM, Junio C Hamano <gits...@pobox.com> wrote: > Mehul Jain <mehul.jain2...@gmail.com> writes: > >> In patch 2/3 and 3/3, there are many tests which requires a branch >> similar to that of "signed" branch, i.e. a branch w

Re: [PATCH v3 0/3] Introduce log.showSignature config variable

2016-06-22 Thread Mehul Jain
On Thu, Jun 23, 2016 at 2:01 AM, Junio C Hamano <gits...@pobox.com> wrote: > Mehul Jain <mehul.jain2...@gmail.com> writes: > >> Add a new configuratation variable "log.showSignature" for git-log >> and related commands. "log.showSignature=true" w

[PATCH v3 2/3] log: add "--no-show-signature" command line option

2016-06-22 Thread Mehul Jain
will make "git logss --no-show-signature" run without showing GPG signature. Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- revision.c | 2 ++ t/t4202-log.sh | 5 + 2 files changed, 7 insertions(+) diff --git a/revision.c b/revision.c index d30d1c4..3546ff9 1006

[PATCH v3 3/3] log: add log.showSignature configuration variable

2016-06-22 Thread Mehul Jain
t-log, git-show, git-whatchanged and git-reflog. Other commands like git-format-patch, git-rev-list are not to be affected by this config variable. Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- Documentation/git-log.txt | 4 builtin/log.c | 6 ++ t/t4

[PATCH v3 1/3] t4202: refactor test

2016-06-22 Thread Mehul Jain
Separate the creation of 'signed' branch so that other tests can take advantage of this branch. Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t4202-log.sh | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/t/t4202-log.sh b/t/t4202-log.sh index 1

[PATCH v3 0/3] Introduce log.showSignature config variable

2016-06-22 Thread Mehul Jain
n previous series [1]. [1]: http://thread.gmane.org/gmane.comp.version-control.git/297648 Mehul Jain (3): t4202: refactoring of test log: add "--no-show-signature" command line option log: add log.showSignature configuration variable Documentation/git-log.txt | 4

Re: [PATCH v2 2/2] log: add log.showSignature configuration variable

2016-06-19 Thread Mehul Jain
Hi Eric, Thanks for your review. On Sun, Jun 19, 2016 at 12:29 PM, Eric Sunshine <sunsh...@sunshineco.com> wrote: > On Sat, Jun 18, 2016 at 8:25 AM, Mehul Jain <mehul.jain2...@gmail.com> wrote: >> diff --git a/t/t4202-log.sh b/t/t4202-log.sh >> @@ -900,6 +900,31

[PATCH v2 2/2] log: add log.showSignature configuration variable

2016-06-18 Thread Mehul Jain
t-log, git-show, git-whatchanged and git-reflog. Other commands like git-format-patch, git-rev-list are not to be affected by this config variable. Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- Documentation/git-log.txt | 4 builtin/log.c | 6 ++ t/t4

[PATCH v2 1/2] log: add "--no-show-signature" command line option

2016-06-18 Thread Mehul Jain
will make "git logss --no-show-signature" run without showing GPG signature. Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- revision.c | 2 ++ t/t4202-log.sh | 10 ++ 2 files changed, 12 insertions(+) diff --git a/revision.c b/revision.c index d30d1c4..3546ff9 1006

[PATCH v2 0/2] Introduce log.showSignature config variable

2016-06-18 Thread Mehul Jain
* A new test has been introduced for "--no-show-signature" option. Previous patch: http://thread.gmane.org/gmane.comp.version-control.git/296474 [1]: http://thread.gmane.org/gmane.comp.version-control.git/296474/focus=296476 Mehul Jain (2): log: add "--no-show-signat

Re: [PATCH 2/2] log: "--no-show-signature" commmand-line option

2016-06-08 Thread Mehul Jain
On Tue, Jun 7, 2016 at 12:20 AM, Junio C Hamano <gits...@pobox.com> wrote: > Mehul Jain <mehul.jain2...@gmail.com> writes: > >> If "log.showSignature=true", then there is no way to override it using >> command line switch. >> >> Teach git-log and

[PATCH 1/2] log: add "log.showsignature" configuration variable

2016-06-05 Thread Mehul Jain
People may want to always use "--show-signature" while using "git log" and related commands. When log.showSignature is set to true, "git log" and related commands will behave as if "--show-signature" was given to them. Signed-off-by: Mehul Jain <mehul

[PATCH 2/2] log: "--no-show-signature" commmand-line option

2016-06-05 Thread Mehul Jain
lem for the following commands: git-log, git-show, git-whatchanged and git-reflog. It does not suggest that we need "log.showSignature" config variable to affect other git commands, as currently "log.showSignature" is only meant to affect git-log, git-show, git-whatchanged and g

[PATCH 0/2] Introduce "log.showSignature" config variable

2016-06-05 Thread Mehul Jain
user wants to disable the setting of "log.showSignature=true" using a command line switch. * Thanks Junio, Jeff and Remi for helping in reference patch. Previous reference patch: http://thread.gmane.org/gmane.comp.version-control.git/295649 Mehul Jain (2): log: ad

Re: [RFC/PATCH 2/2] log: add "--no-show-signature" command line option

2016-05-27 Thread Mehul Jain
On Thu, May 26, 2016 at 10:52 PM, Junio C Hamano <gits...@pobox.com> wrote: > Jeff King <p...@peff.net> writes: > >> On Thu, May 26, 2016 at 06:36:47PM +0530, Mehul Jain wrote: >> >>> If "log.showsignature=true", then there is no way to override it

Re: [RFC/PATCH 1/2] log: add "log.showsignature" configuration variable

2016-05-27 Thread Mehul Jain
On Thu, May 26, 2016 at 10:29 PM, Jeff King <p...@peff.net> wrote: > On Thu, May 26, 2016 at 06:36:46PM +0530, Mehul Jain wrote: > The documentation here mentions "log" and "show". But I think this will > affect other programs, too, including "whatchanged&

Re: [RFC/PATCH 2/2] log: add "--no-show-signature" command line option

2016-05-26 Thread Mehul Jain
Hi, Thanks for your input. On Thu, May 26, 2016 at 10:02 PM, Jeff King <p...@peff.net> wrote: > On Thu, May 26, 2016 at 06:36:47PM +0530, Mehul Jain wrote: >> diff --git a/t/t4202-log.sh b/t/t4202-log.sh >> index 36be9a1..ea24259 100755 >> --- a/t/t4202-log

Re: [RFC/PATCH 1/2] log: add "log.showsignature" configuration variable

2016-05-26 Thread Mehul Jain
On Thu, May 26, 2016 at 9:13 PM, Remi Galan Alfonso wrote: > Sorry, I should have made explicit what went through my mind. > "When log.showsignature set true" doesn't sound right to me, while > "When log.showsignature is set to true" sounds better,

Re: [RFC/PATCH 1/2] log: add "log.showsignature" configuration variable

2016-05-26 Thread Mehul Jain
Hi Remi, Thanks for your input. On Thu, May 26, 2016 at 7:12 PM, Remi Galan Alfonso <remi.galan-alfo...@ensimag.grenoble-inp.fr> wrote: > Hi Mehul, > > Mehul Jain <mehul.jain2...@gmail.com> writes: >> When log.showsignature set true, "git log"

[RFC/PATCH 2/2] log: add "--no-show-signature" command line option

2016-05-26 Thread Mehul Jain
If "log.showsignature=true", then there is no way to override it using command line switch. Teach "git log" and "git show" about "--no-show-signature" command line option. Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- revision.c | 2 +

[RFC/PATCH 0/2] Introduce "log.showSignature" config variable

2016-05-26 Thread Mehul Jain
es the problem: what if user wants to disable the setting of "log.showSignature=true" using a command line switch. Previous discussion on this: http://thread.gmane.org/gmane.comp.version-control.git/295405 Mehul Jain (2): log: add "log.showsignature" conf

[RFC/PATCH 1/2] log: add "log.showsignature" configuration variable

2016-05-26 Thread Mehul Jain
People may want to always use "--show-signature" while using "git log" or "git show". When log.showsignature set true, "git log" and "git show" will behave as "--show-signature" was given to them. Signed-off-by: Mehul Jain &l

Re: Please add a git config option to make --show-signature the default

2016-05-25 Thread Mehul Jain
Hi, On Wed, May 25, 2016 at 9:28 AM, Austin English wrote: > I'll try > to submit my own patch. In the meantime, it seems appropriate to file > a bug so that others can have the opportunity to solve the problem if > they're interested. If you haven't started working on

Re: [PATCH 5/5] t/t5520: test --[no-]autostash with pull.rebase=true

2016-04-04 Thread Mehul Jain
On Mon, Apr 4, 2016 at 10:22 PM, Matthieu Moy wrote: > I think it would be much simpler to drop the loop, and write instead > something like (untested): I tested it (with few minor changes), and worked fine. test_autostash () { OLDIFS=$IFS IFS='='

Re: [PATCH v2 0/7] t5520: tests for --[no-]autostash option

2016-04-04 Thread Mehul Jain
On Mon, Apr 4, 2016 at 10:30 PM, Junio C Hamano <gits...@pobox.com> wrote: > Matthieu Moy <matthieu@grenoble-inp.fr> writes: > >> Mehul Jain <mehul.jain2...@gmail.com> writes: >> >>> -test_rebase_autostash () { >>> +test_pull_

Re: [PATCH v2 0/7] t5520: tests for --[no-]autostash option

2016-04-04 Thread Mehul Jain
On Mon, Apr 4, 2016 at 1:01 PM, Matthieu Moy <matthieu@grenoble-inp.fr> wrote: > Mehul Jain <mehul.jain2...@gmail.com> writes: > >> -test_rebase_autostash () { >> +test_pull_autostash () { >> git reset --hard before-rebase && >>

Re: [PATCH 5/5] t/t5520: test --[no-]autostash with pull.rebase=true

2016-04-04 Thread Mehul Jain
On Mon, Apr 4, 2016 at 12:58 AM, Eric Sunshine <sunsh...@sunshineco.com> wrote: > On Fri, Apr 1, 2016 at 6:27 AM, Mehul Jain <mehul.jain2...@gmail.com> wrote: >> In test_autostash() there's a line >> >> echo test_cmp_rev HEAD^ copy && >> >>

[PATCH v2 6/7] t5520: reduce commom lines of code

2016-04-03 Thread Mehul Jain
These two tests are almost similar and thus can be folded in a for-loop. Helped-by: Eric Sunshine <sunsh...@sunshineco.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t5520-pull.sh | 16 +++- 1 file changed, 7 insertions(+), 9 deletions(-) diff --g

Re: [PATCH v2 6/7] t5520: reduce commom lines of code

2016-04-03 Thread Mehul Jain
On Sun, Apr 3, 2016 at 12:20 AM, Johannes Sixt <j...@kdbg.org> wrote: > Am 02.04.2016 um 19:58 schrieb Mehul Jain: >> +for i in --autostash --no-autostash >> +do >> + test_expect_success "pull $i (without --rebase) is illegal" ' >> +

[PATCH v2 5/7] t5520: factor out common code

2016-04-02 Thread Mehul Jain
Three tests contains repetitive lines of code. Factor out common code into test_pull_autostash_fail() and then call it in these tests. Helped-by: Eric Sunshine <sunsh...@sunshineco.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t5520-pull.sh | 26 +++--

[PATCH v2 7/7] t5520: test --[no-]autostash with pull.rebase=true

2016-04-02 Thread Mehul Jain
tion works with pull.rebase=true. Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t5520-pull.sh | 10 ++ 1 file changed, 10 insertions(+) diff --git a/t/t5520-pull.sh b/t/t5520-pull.sh index e12af96..bed75f5 100755 --- a/t/t5520-pull.sh +++ b/t/t5520-pull.sh @

[PATCH v2 6/7] t5520: reduce commom lines of code

2016-04-02 Thread Mehul Jain
These two tests are almost similar and thus can be folded in a for-loop. Helped-by: Eric Sunshine <sunsh...@sunshineco.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t5520-pull.sh | 16 +++- 1 file changed, 7 insertions(+), 9 deletions(-) diff --g

[PATCH v2 4/7] t5520: factor out common code

2016-04-02 Thread Mehul Jain
Four tests contains repetitive lines of code. Factor out common code into test_pull_autostash() and then call it in these tests. Helped-by: Eric Sunshine <sunsh...@sunshineco.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t5520-

[PATCH v2 3/7] t5520: use better test to check stderr output

2016-04-02 Thread Mehul Jain
Checking stderr output using test_i18ncmp may lead to test failure as some shells write trace output to stderr when run under 'set -x'. Use test_i18ngrep instead of test_i18ncmp. Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t5520-pull.sh | 10 -- 1 file chan

[PATCH v2 1/7] t5520: use consistent capitalization in test titles

2016-04-02 Thread Mehul Jain
Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t5520-pull.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/t/t5520-pull.sh b/t/t5520-pull.sh index 745e59e..5be39df 100755 --- a/t/t5520-pull.sh +++ b/t/t5520-pull.sh @@ -267,7 +267,7 @@ test_expect_s

[PATCH v2 2/7] t5520: ensure consistent test conditions

2016-04-02 Thread Mehul Jain
rebase.autostash. Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t5520-pull.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/t/t5520-pull.sh b/t/t5520-pull.sh index 5be39df..9ee2218 100755 --- a/t/t5520-pull.sh +++ b/t/t5520-pull.sh @@ -279,6 +279,7 @@ test_expect_success 'pull --

[PATCH v2 0/7] t5520: tests for --[no-]autostash option

2016-04-02 Thread Mehul Jain
e)" = dirty && - test "$(cat file)" = "modified again" + test_pull_autostash --autostash ' test_expect_success 'pull --no-autostash & pull.rebase=true' ' test_config pull.rebase true && - git reset --hard before-rebase &am

Re: [PATCH 5/5] t/t5520: test --[no-]autostash with pull.rebase=true

2016-04-01 Thread Mehul Jain
Hi Eric, On Thu, Mar 31, 2016 at 2:01 AM, Eric Sunshine wrote: > One other possibility would be to make this all table-driven by > collecting all of the above state information into a table and then > feeding that into a function (either as its argument list or via >

Re: [PATCH 5/5] t/t5520: test --[no-]autostash with pull.rebase=true

2016-03-30 Thread Mehul Jain
Hi Eric, Thanks for the reviews on this series. On Wed, Mar 30, 2016 at 2:46 AM, Eric Sunshine wrote: > With the exception of the missing --rebase argument, this is exactly > the same code as in test_rebase_autostash(), right? Rather than > repeating this code yet

[PATCH 5/5] t/t5520: test --[no-]autostash with pull.rebase=true

2016-03-29 Thread Mehul Jain
tion works with pull.rebase=true. Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t5520-pull.sh | 20 1 file changed, 20 insertions(+) diff --git a/t/t5520-pull.sh b/t/t5520-pull.sh index 2611170..4da9e52 100755 --- a/t/t5520-pull.sh +++ b/t/t5520-pull.sh @

[PATCH 4/5] t/t5520: modify tests to reduce common code

2016-03-29 Thread Mehul Jain
com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t5520-pull.sh | 100 +++- 1 file changed, 41 insertions(+), 59 deletions(-) diff --git a/t/t5520-pull.sh b/t/t5520-pull.sh index d03cb84..2611170 100755 --- a/t/t5520-pul

[PATCH 1/5] t/t5520: change rebase.autoStash to rebase.autostash

2016-03-29 Thread Mehul Jain
Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t5520-pull.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/t/t5520-pull.sh b/t/t5520-pull.sh index 745e59e..5be39df 100755 --- a/t/t5520-pull.sh +++ b/t/t5520-pull.sh @@ -267,7 +267,7 @@ test_expect_s

[PATCH 0/5] modify tests for --[no-]autostash option

2016-03-29 Thread Mehul Jain
when "git pull --[no-]autostash" is called with pull.rebase=true. Mehul Jain (5): t/t5520: change rebase.autoStash to rebase.autostash t/t5520: explicitly unset rebase.autostash t/t5520: use test_i18ngrep instead of test_cmp t/t5520: modify tests to reduce common code

[PATCH 3/5] t/t5520: use test_i18ngrep instead of test_cmp

2016-03-29 Thread Mehul Jain
test_cmp is used for error checking when test_i18ngrep could be used. Use test_i18ngrep to check for the valid error. Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t5520-pull.sh | 10 -- 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/t/t5520-pull.sh b/t

[PATCH 2/5] t/t5520: explicitly unset rebase.autostash

2016-03-29 Thread Mehul Jain
Tests title suggest that tests are done with rebase.autostash unset, but doesn not take any action to make sure that it is indeed unset. Make sure that rebase.autostash is unset by explicitly setting it. Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t5520-pull.sh | 2 ++

Re: [PATCH v10 2/2] pull --rebase: add --[no-]autostash flag

2016-03-25 Thread Mehul Jain
On Sat, Mar 26, 2016 at 12:07 AM, Matthieu Moy wrote: > I think you should also change one of the tests to use pull.resbase=true > so that this behavior is properly tested. Sure. I will add this test in the re-roll. Thanks, Mehul -- To unsubscribe from this list:

Re: [PATCH v10 2/2] pull --rebase: add --[no-]autostash flag

2016-03-25 Thread Mehul Jain
On Fri, Mar 25, 2016 at 2:35 PM, Matthieu Moy <matthieu@grenoble-inp.fr> wrote: > Mehul Jain <mehul.jain2...@gmail.com> writes: > >> +--autostash:: >> +--no-autostash:: >> + Before starting rebase, stash local modifications away (see >> +

Re: [PATCH v10 2/2] pull --rebase: add --[no-]autostash flag

2016-03-25 Thread Mehul Jain
On Fri, Mar 25, 2016 at 2:01 PM, Eric Sunshine wrote: >> +test_expect_success 'pull --rebase --autostash & rebase.autostash=true' ' > > Nit: Some of the test titles spell this as "rebase.autostash" while > others use "rebase.autoStash". That's a mistake. All test titles

Re: [PATCH v10 0/2] introduce --[no-]autostash command line flag

2016-03-25 Thread Mehul Jain
On Fri, Mar 25, 2016 at 12:53 PM, Eric Sunshine <sunsh...@sunshineco.com> wrote: > On Mon, Mar 21, 2016 at 2:18 PM, Mehul Jain <mehul.jain2...@gmail.com> wrote: >> Changes introduced w.r.t. previous patch: >> [...] >> * Two more tests are added to

Re: Regarding GSoC 2016

2016-03-24 Thread Mehul Jain
On Thu, Mar 24, 2016 at 11:13 PM, Saurabh Jain wrote: > The proposal can be accessed here. > 5mWF_cqoZS6IUvGr6CVu5SmkbZk/edit?usp=sharing> It's broken I guess. Also Cc Carlos Martín Nieto . He is

Re: git-apply does not work in a sub-directory of a Git repository

2016-03-23 Thread Mehul Jain
On Wed, Mar 23, 2016 at 8:51 PM, Junio C Hamano wrote: > I think we do have --no-index (which is why I am largely ignoring > the rest of your message as uninformed speculation for now). --no-index command line flag is there for git-apply but unfortunately not documented. Also

git-apply does not work in a sub-directory of a Git repository

2016-03-22 Thread Mehul Jain
Hello everyone, Recently while using git-apply, I observed that if git-apply is used in a sub-directory of a Git repository then it silently dies without doing anything. Here's what I did ~ $mkdir example ~ $cd example example $git init Initialized empty Git repository in /home/mj/example/.git/

[PATCH v10 2/2] pull --rebase: add --[no-]autostash flag

2016-03-21 Thread Mehul Jain
Paul Tan <pyoka...@gmail.com> Helped-by: Eric Sunshine <sunsh...@sunshineco.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- Documentation/git-pull.txt | 9 ++ builtin/pull.c | 12 t/t5520-pull.sh| 70 +

[PATCH v10 2/2] pull --rebase: add --[no-]autostash flag

2016-03-21 Thread Mehul Jain
Paul Tan <pyoka...@gmail.com> Helped-by: Eric Sunshine <sunsh...@sunshineco.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- Documentation/git-pull.txt | 9 ++ builtin/pull.c | 12 t/t5520-pull.sh| 70 +

[PATCH v10 0/2] introduce --[no-]autostash command line flag

2016-03-21 Thread Mehul Jain
ull with rebase: Your index contains uncommitted changes." err +' + +test_expect_success 'pull --autostash (without --rebase) should error out' ' + test_must_fail git pull --autostash . copy 2>actual && + echo "fatal: --[no-]autostash option is only valid with --re

[PATCH v10 1/2] git-pull.c: introduce git_pull_config()

2016-03-21 Thread Mehul Jain
Helped-by: Junio C Hamano <gits...@pobox.com> Helped-by: Paul Tan <pyoka...@gmail.com> Helped-by: Eric Sunshine <sunsh...@sunshineco.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- builtin/pull.c | 18 +++--- 1 file changed, 15 insertions(+), 3

Re: [PATCH v9 2/2] pull --rebase: add --[no-]autostash flag

2016-03-19 Thread Mehul Jain
On Fri, Mar 18, 2016 at 9:54 AM, Eric Sunshine wrote: > Since this is now a patch series rather than a single patch, another > way to help reviewers is to use a cover letter (see git-format-patch > --cover-letter) where you'd explain the changes, and, importantly, >

[PATCH v9 1/2] git-pull.c: introduce git_pull_config()

2016-03-19 Thread Mehul Jain
Helped-by: Junio C Hamano <gits...@pobox.com> Helped-by: Paul Tan <pyoka...@gmail.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- previous patches: http://thread.gmane.org/gmane.comp.version-control.git/287709 builtin/pull.c | 19 ++- 1 file changed,

[PATCH v9 2/2] pull --rebase: add --[no-]autostash flag

2016-03-19 Thread Mehul Jain
Paul Tan <pyoka...@gmail.com> Helped-by: Eric Sunshine <sunsh...@sunshineco.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- previous patches: http://thread.gmane.org/gmane.comp.version-control.git/287709 Changes: * Modified documentation * "git pull

Re: [PATCH v9 2/2] pull --rebase: add --[no-]autostash flag

2016-03-19 Thread Mehul Jain
On Fri, Mar 18, 2016 at 10:09 AM, Eric Sunshine <sunsh...@sunshineco.com> wrote: > On Fri, Mar 18, 2016 at 12:24 AM, Eric Sunshine <sunsh...@sunshineco.com> > wrote: >> On Thu, Mar 17, 2016 at 12:49 PM, Mehul Jain <mehul.jain2...@gmail.com> >> wrote: >>&

Re: [PATCH 2/2] pull --rebase: add --[no-]autostash flag

2016-03-19 Thread Mehul Jain
Hello Eric, I tried out this approach and here's the result. --- diff --git a/builtin/pull.c b/builtin/pull.c index b5b0255..0ce007d 100644 --- a/builtin/pull.c +++ b/builtin/pull.c @@ -86,6 +86,7 @@ static char *opt_commit; static char *opt_edit; static char *opt_ff; static char

Re: [PATCH 2/2] pull --rebase: add --[no-]autostash flag

2016-03-15 Thread Mehul Jain
On Wed, Mar 16, 2016 at 3:13 AM, Eric Sunshine wrote: >> diff --git a/Documentation/git-pull.txt b/Documentation/git-pull.txt >> @@ -128,6 +128,15 @@ unless you have read linkgit:git-rebase[1] carefully. >> +--autostash:: >> +--no-autostash:: >> + Before starting

[PATCH 2/2] pull --rebase: add --[no-]autostash flag

2016-03-15 Thread Mehul Jain
Paul Tan <pyoka...@gmail.com> Helped-by: Eric Sunshine <sunsh...@sunshineco.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- previous patches: http://thread.gmane.org/gmane.comp.version-control.git/287709 Documentation/git-pull.txt | 9 +

[PATCH 1/2] git-pull.c: introduce git_pull_config()

2016-03-15 Thread Mehul Jain
Helped-by: Junio C Hamano <gits...@pobox.com> Helped-by: Paul Tan <pyoka...@gmail.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- Previous patches: http://thread.gmane.org/gmane.comp.version-control.git/287709 Change: config_autostash initialized with

Re: [PATCH v7 2/2] pull --rebase: add --[no-]autostash flag

2016-03-11 Thread Mehul Jain
On Fri, Mar 11, 2016 at 10:21 AM, Paul Tan wrote: > Stepping back a bit, the only reason why we introduced opt_autostash = > -1 as a possible value is because we need to detect if > --[no-]autostash is being used with git-merge. I consider that a > kludge, because if git-merge

Re: [PATCH v7 2/2] pull --rebase: add --[no-]autostash flag

2016-03-11 Thread Mehul Jain
On Fri, Mar 11, 2016 at 7:00 PM, Matthieu Moy wrote: > What Junio says is that you don't need to write > > static int config_autostash = 0; > > since it is equivalent to > > static int config_autostash; > > But there's nothing wrong with having a static variable

Re: [PATCH v7 2/2] pull --rebase: add --[no-]autostash flag

2016-03-11 Thread Mehul Jain
On Fri, Mar 11, 2016 at 10:21 AM, Paul Tan wrote: >> static int config_autostash = -1; > > Hmm, why can't config_autostash just default to 0? Previously Junio recommended not to explicitly initialize a static to 0 (or NULL).

[PATCH v7 1/2] git-pull.c: introduce git_pull_config()

2016-03-08 Thread Mehul Jain
Helped-by: Junio C Hamano <gits...@pobox.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- previous patches: $gname287709 This is a clean-up patch to add --[no-]autostash option to "git pull --rebase". builtin/pull.c | 18 ++ 1 file changed, 14

[PATCH v7 2/2] pull --rebase: add --[no-]autostash flag

2016-03-08 Thread Mehul Jain
Paul Tan <pyoka...@gmail.com> Helped-by: Eric Sunshine <sunsh...@sunshineco.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- Previous patches: $gname287709 Changes: - Slight change is documentation. Documentation/git-pull.txt | 9 + b

[PATCH v6 2/2] pull --rebase: add --[no-]autostash flag

2016-03-08 Thread Mehul Jain
Paul Tan <pyoka...@gmail.com> Helped-by: Eric Sunshine <sunsh...@sunshineco.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- Previous patches: $gname287709 Changes: - Slight change is documentation. Documentation/git-pull.txt | 9 + b

[PATCH v6 1/2] git-pull.c: introduce git_pull_config()

2016-03-08 Thread Mehul Jain
Helped-by: Junio C Hamano <gits...@pobox.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- previous patches: $gname287709 This is a clean-up patch to add --[no-]autostash option to "git pull --rebase". builtin/pull.c | 18 ++ 1 file changed, 14

[PATCH v5] pull --rebase: add --[no-]autostash flag

2016-03-07 Thread Mehul Jain
d-by: Junio C Hamano <gits...@pobox.com> Helped-by: Paul Tan <pyoka...@gmail.com> Helped-by: Eric Sunshine <sunsh...@sunshineco.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- Previous patches: $gname287709 Changes: * Documentation modified * Introduced a

Re: [PATCH v4] pull --rebase: add --[no-]autostash flag

2016-03-07 Thread Mehul Jain
Hi Junio, Thanks for the thorough review. On Sat, Mar 5, 2016 at 10:34 PM, Junio C Hamano wrote: > Is it worth checking the case where autostash kicks in, rebase > itself is completed successfully, but the final "stash pop" fails in > conflict? I am thinking aloud and just

Re: [PATCH v4] pull --rebase: add --[no-]autostash flag

2016-03-05 Thread Mehul Jain
On Sat, Mar 5, 2016 at 3:22 PM, Mehul Jain <mehul.jain2...@gmail.com> wrote: > Changes: > * --no-autostash is passed to git-rebase (suggested by Paul) > > * Error message changed when "git pull --[no-]autostash" is called. > > * If rebase

[PATCH v4] pull --rebase: add --[no-]autostash flag

2016-03-05 Thread Mehul Jain
Paul Tan <pyoka...@gmail.com> Helped-by: Eric Sunshine <sunsh...@sunshineco.com> Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- Previous patches: $gname287709 Changes: * --no-autostash is passed to git-rebase (suggested by Paul) * Error message ch

Re: [PATCH v3 2/3] test: add test for --[no-]autostash flag

2016-03-03 Thread Mehul Jain
On Thu, Mar 3, 2016 at 11:01 PM, Matthieu Moy wrote: > There's no need to split code/test/doc into separate patches, except if > your patches are getting really huge. As a reviewer, I like having tests > and doc in the same patch because they describe the intention

Re: [PATCH v3 1/3] pull --rebase: add --[no-]autostash flag

2016-03-03 Thread Mehul Jain
On Thu, Mar 3, 2016 at 10:54 PM, Matthieu Moy <matthieu@grenoble-inp.fr> wrote: > Mehul Jain <mehul.jain2...@gmail.com> writes: > >> If rebase.autoStash configuration variable is >> set, there is no way to override it for >> "git pull --rebase"

Re: [PATCH v3 3/3] Documentation/git-pull: document --[no-]autostash option

2016-03-03 Thread Mehul Jain
On Thu, Mar 3, 2016 at 10:44 PM, Junio C Hamano wrote: > Should this entry this verbose? > > - Is there a non-temporary stash? > > - I think "This means that ..." is totally unnecessary. > > - It probably makes sense to have "This option is only valid..." as >a separate

[PATCH v3 3/3] Documentation/git-pull: document --[no-]autostash option

2016-03-03 Thread Mehul Jain
Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- Documentation/git-pull.txt | 15 +++ 1 file changed, 15 insertions(+) diff --git a/Documentation/git-pull.txt b/Documentation/git-pull.txt index a62a2a6..a593972 100644 --- a/Documentation/git-pull.txt +++ b/Documentati

[PATCH v3 2/3] test: add test for --[no-]autostash flag

2016-03-03 Thread Mehul Jain
Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- t/t5520-pull.sh | 19 +++ t/t5521-pull-options.sh | 16 2 files changed, 35 insertions(+) diff --git a/t/t5520-pull.sh b/t/t5520-pull.sh index c952d5e..f5d1d31 100755 --- a/t/t5520-pull.sh +

[PATCH v3 1/3] pull --rebase: add --[no-]autostash flag

2016-03-03 Thread Mehul Jain
t;git rebase" understands the --[no]autostash option, it's just a matter of passing the option to underlying "git rebase" when "git pull --rebase" is called. Helped-by: Matthieu Moy <matthieu@grenoble-inp.fr> Helped-by: Junio C Hamano <gits...@pobox.com> Help

Re: [PATCH v2 1/2] pull --rebase: add --[no-]autostash flag

2016-02-28 Thread Mehul Jain
On Sun, Feb 28, 2016 at 12:56 AM, Junio C Hamano <gits...@pobox.com> wrote: > Mehul Jain <mehul.jain2...@gmail.com> writes: > >> git pull --rebase understands --[no-]autostash flag. >> >> This flag overrides config variable "rebase.autoStash" >>

[PATCH v2 2/2] Documentation/git-pull.txt: teach 'git pull --rebase' the --[no-]autostash option.

2016-02-27 Thread Mehul Jain
ich then runs rebase on a dirty worktree. With "--no-autostash" option, the command will die if the worktree is dirty, before calling rebase. Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- Documentation/git-pull.txt | 16 1 file changed, 16 insertions(+) dif

[PATCH v2 1/2] pull --rebase: add --[no-]autostash flag

2016-02-27 Thread Mehul Jain
ich then runs rebase on a dirty worktree. With "--no-autostash" option, the command will die if the worktree is dirty, before calling rebase. Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- Thanks to Paul and Matthieu for comments on previous round. Changes: - --autostash

Re: [PATCH] Add --no-autostash flag to git pull --rebase

2016-02-26 Thread Mehul Jain
t; + test_must_be_empty err && >> + test_must_be_empty out) >> +' >> + >> +test_expect_success 'git pull -v --rebase --no-autostash' ' >> + mkdir clonedvrbnas && >> + (cd clonedvrbnas && git init && >> +

Re: [GSoC] Microproject :- Teaching git pull --rebase the --no-autostash flag

2016-02-26 Thread Mehul Jain
On Fri, Feb 26, 2016 at 5:21 PM, Paul Tan wrote: > That was the point of the microproject ;-). --[no-]autostash means > both --autostash and --no-autostash. Oops, my bad. I will add the necessary changes :-). Thanks, Mehul -- To unsubscribe from this list: send the line

[PATCH] Add --no-autostash flag to git pull --rebase

2016-02-26 Thread Mehul Jain
ebase.autostash"(if "rebase.autostash" is not set then git pull --rebase will die if directory is dirty). Signed-off-by: Mehul Jain <mehul.jain2...@gmail.com> --- builtin/pull.c | 12 t/t5520-pull.sh | 8 t/t5521-pull-options.sh | 24

[GSoC] Microproject :- Teaching git pull --rebase the --no-autostash flag

2016-02-26 Thread Mehul Jain
ebase. I would like to know your opinion on this option. Thanks! Mehul Jain (1): Add --no-autostash flag to git pull --rebase builtin/pull.c | 12 t/t5520-pull.sh | 8 t/t5521-pull-options.sh | 24 3 files changed, 40 insertions(+), 4 de

Re: GSoC 2016: Microproject

2016-02-22 Thread Mehul Jain
it. Thanks Duy. :) All tests passed. I configured apache server to listen to the ports tests were trying to access. Thanks Lars. I tested on Traivs-CI, worked fine. :) Mehul Jain -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to major

Re: GSoC 2016: Microproject

2016-02-22 Thread Mehul Jain
On Mon, Feb 22, 2016 at 3:50 PM, Duy Nguyen wrote: > You may have an http server installed but not suitable for these > tests. Try running one test file alone with -v -i, e.g. > ./t5539-fetch-http-shallow.sh -v -i and post the output. Here's the output :- expecting success:

Re: GSoC 2016: Microproject

2016-02-22 Thread Mehul Jain
proxy server which blocks all ports except 80 and 443. Also my .gitconfig file is properly configured for proxy. Can these tests failure be triggered because of proxy server? Thanks, Mehul Jain -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a messag

Re: GSoC 2016: Microproject

2016-02-21 Thread Mehul Jain
1/.git && # test_path_is_file possible_sub1/hello.world && # test_path_is_missing to_clean # I haven't made any commits/changes in the master branch. Can you please suggest where things are going wrong. Thanks Mehul Jain -- 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.kernel.org/majordomo-info.html

Re: GSoC 2016: Microproject

2016-02-21 Thread Mehul Jain
est for "pull --rebase --[no-]autostash fails with dirty working tree and rebase.autostash set" should be added to t/t5520-pull.sh. Have I made the right observation? Thanks, Mehul Jain -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to maj

Re: GSoC 2016: Microproject

2016-02-20 Thread Mehul Jain
]: *** [t5539-fetch-http-shallow.sh] Error 1 make[1]: Leaving directory `/home/mj/git/t' make: *** [test] Error 2 Is this test failure usual with linux based system or just happened with me. I'm running Ubuntu 14.04. thanks, Mehul Jain On Fri, Feb 19, 2016 at 11:20 PM, Stefan Beller <sbel...

Re: GSoC 2016: Microproject

2016-02-19 Thread Mehul Jain
e best place to write test for this case. Mehul Jain -- 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.kernel.org/majordomo-info.html

Re: GSoC 2016: Microproject

2016-02-19 Thread Mehul Jain
"--[no-]autostash" means "rebase.autostash" should be set false for current execution of command "git pull --rebase". So do I have to write a test for this new option? Mehul Jain -- 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.kernel.org/majordomo-info.html

GSoC 2016: Microproject

2016-02-19 Thread Mehul Jain
Hello everyone, I'm Mehul Jain. I'm looking for participating in GSoC 2016. I've started work on a Microproject" Teach git pull --rebase the --no-autostash" option. While looking at Git's source code I have made following observation: In the pull.c file 1. git_config_get_bool(

GSoC 2016

2016-02-18 Thread Mehul Jain
Hello everyone, I'm Mehul Jain. I'm looking for participating in GSoC 2016. I've started work on a Microproject" Teach git pull --rebase the --no-autostash" option. While looking at Git's source code I have made following observation: In the pull.c file 1. git_config_get_bool(