git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* git log --ignore-space-change -L start,end:file does not ignore indentation changes
@ 2017-04-23  6:08 Дилян Палаузов
  0 siblings, 0 replies; only message in thread
From: Дилян Палаузов @ 2017-04-23  6:08 UTC (permalink / raw)
  To: git

Hello,

$ git version
git version 2.12.2.89.g49800c940

$ git init
Initialized empty Git repository in .git/

$ cat a.c
int main() {
  int result;
}

$git add a.c

$git commit -m I
[master (root-commit) ef9ab63] I
  1 file changed, 3 insertions(+)
  create mode 100644 a.c

$cat a.c  # now the indentation of result changed
cat a.c
int main() {
    int result;
    return 0;
}

$git commit -am J
[master 1bed130] J
  1 file changed, 2 insertions(+), 1 deletion(-)

$git -oneline -b -L:main:a.c
1bed130 J

diff --git a/a.c b/a.c
--- a/a.c
+++ b/a.c
@@ -1,3 +1,4 @@
  int main() {
- int result;
+   int result;
+   return 0;
  }
ef9ab63 I

diff --git a/a.c b/a.c
--- /dev/null
+++ b/a.c
@@ -0,0 +1,3 @@
+int main() {
+ int result;
+}

I expect that the result-line is not displayed as changed, when git log 
is called with -b.

Likewise:
git log --oneline  -b -L2,2:a.c
1bed130 J

diff --git a/a.c b/a.c
--- a/a.c
+++ b/a.c
@@ -2,1 +2,1 @@
- int result;
+   int result;
ef9ab63 I

diff --git a/a.c b/a.c
--- /dev/null
+++ b/a.c
@@ -0,0 +2,1 @@
+ int result;

Regards
   Дилян

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2017-04-23  6:29 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-04-23  6:08 git log --ignore-space-change -L start,end:file does not ignore indentation changes Дилян Палаузов

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).