git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Matthias Lederhofer <matled@gmx.net>
To: Jason Sewall <jasonsewall@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: Strange diff behavior?
Date: Thu, 21 Jun 2007 08:50:44 +0200	[thread overview]
Message-ID: <20070621065043.GA30521@moooo.ath.cx> (raw)
In-Reply-To: <31e9dd080706201802h9dcbffawd82575d09e082155@mail.gmail.com>

Jason Sewall <jasonsewall@gmail.com> wrote:
> It seems like every change listed after the first one is meaningless.
> I really think I just don't understand something about the diff
> algorithm. Can someone tell my why those empty lines are recorded as
> changes?

This are whitespace changes.

    $ git diff --color

marks whitespaces at the end of the line with a red background color
so you can see what changed.  I also use vim with :set list to see
whitespace changes, e.g.

    $ git diff | vim -c 'set list' -

If you like to have colors (not just in diff) permnanently you can add
this to your .git/config or ~/.gitconfig:

    [color]
        branch = auto
        diff = auto
        status = auto
        pager = true

See also git-config(1) for more information on these and other
configuration options.

  parent reply	other threads:[~2007-06-21  6:50 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-21  1:02 Strange diff behavior? Jason Sewall
2007-06-21  1:13 ` Johannes Schindelin
2007-06-21  6:47   ` Raimund Bauer
2007-06-21 10:31     ` Johannes Schindelin
2007-06-21 16:46       ` Jason Sewall
2007-06-21  6:50 ` Matthias Lederhofer [this message]
2007-06-21  7:02   ` Jason Sewall

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

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

  git send-email \
    --in-reply-to=20070621065043.GA30521@moooo.ath.cx \
    --to=matled@gmx.net \
    --cc=git@vger.kernel.org \
    --cc=jasonsewall@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.
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 NNTP newsgroup(s).