git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Christian Couder <christian.couder@gmail.com>
To: Kapil Jain <jkapil.cs@gmail.com>
Cc: git <git@vger.kernel.org>, Thomas Gummerer <t.gummerer@gmail.com>
Subject: Re: [GSoC][RFC/PATCH] userdiff: added support for diffing shell scripts
Date: Sun, 24 Mar 2019 10:19:12 +0100	[thread overview]
Message-ID: <CAP8UFD0cWSTZPqqVwTFyYL06S+6aT_EiLPW6jUE0AH9puxevmg@mail.gmail.com> (raw)
In-Reply-To: <CAMknYEMBYxp1QJ3Ds9dmuS4ccHKtExx33d_Kv63UOwaUMm5oUQ@mail.gmail.com>

On Sun, Mar 24, 2019 at 9:04 AM Kapil Jain <jkapil.cs@gmail.com> wrote:
>
> On Sun, Mar 24, 2019 at 1:34 AM Christian Couder
> <christian.couder@gmail.com> wrote:
> >
> > To save some work by people who could help you, it might be a good
> > idea to show the output of the failing test, for example the output of
> > `./t4034-diff-words.sh -i -v` or `./t4034-diff-words.sh -i -v -x`.
>
> Looks like i just needed to know about -i, -v and -x switches, they
> helped in debugging.
> The problem was with the expect file. It is resolved now.

Great!

> Thanks, will be resubmitting with updated expect file.

It looks like you sent "[GSoC][RFC/PATCH 2/2] userdiff: added shell
script support, clears test". I think though that it should have been
named "[GSoC][RFC/PATCH v2] userdiff: added shell script support,
clears test".

"2/2" means that it is patch number 2 in a patch series that has 2
patches (which should be marked with "1/2" and "2/2"). When
resubmitting an already submitted patch (or patch series) we ask for a
version number like "v2", "v3", so that we can know that it has
already been submitted.

`git format-patch -v 2 ...` will automatically add "v2".

> is the parser used to parse the expect file specific to git ? or is it
> some general one ?

The test_language_driver() function used to test the regexps is
defined in t4034-diff-words.sh and it calls the word_diff() function
(also defined in t4034-diff-words.sh) which is:

word_diff () {
    test_must_fail git diff --no-index "$@" pre post >output &&
    test_decode_color <output >output.decrypted &&
    test_cmp expect output.decrypted
}

So it uses test_decode_color() and test_cmp() that are defined in
t/test-lib-functions.sh. test_cmp() in turn is defined using
GIT_TEST_CMP which is usually either "diff -u" or "diff -c".

  reply	other threads:[~2019-03-24  9:19 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-22 16:06 [GSoC][RFC/PATCH] userdiff: added support for diffing shell scripts Kapil Jain
2019-03-23 20:04 ` Christian Couder
2019-03-24  8:04   ` Kapil Jain
2019-03-24  9:19     ` Christian Couder [this message]
2019-03-24 10:04       ` Kapil Jain
2019-03-28 21:30         ` Thomas Gummerer
2019-03-29 12:13           ` Kapil Jain
2019-03-29 19:07             ` Thomas Gummerer
2019-03-24  8:45   ` [GSoC][RFC/PATCH 2/2] userdiff: added shell script support, clears test Kapil Jain

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAP8UFD0cWSTZPqqVwTFyYL06S+6aT_EiLPW6jUE0AH9puxevmg@mail.gmail.com \
    --to=christian.couder@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=jkapil.cs@gmail.com \
    --cc=t.gummerer@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).