From: Jack Adrian Zappa <hidden> Date: 2017-02-08 21:39:15
That was it. I have a .gitattributes file in my home directory.
Ahhh, but it's not in my %userprofile% directory, but in my ~
directory.
A bit confusing having 2 home directories. I made a link to my
.gitconfig, but forgot to make a link to my .gitattributes.
Thanks.
A
On Wed, Feb 8, 2017 at 4:05 PM, Samuel Lijin [off-list ref] wrote:
Double check .gitattributes?
On Feb 8, 2017 2:58 PM, "Jack Adrian Zappa" [off-list ref] wrote:
quoted
Thanks Samuel,
That example showed that there must be something wrong in my .git
directory, because with it, I'm getting the correct output. Moving
the same lines to my .git/config didn't work.
On Wed, Feb 8, 2017 at 3:46 PM, Samuel Lijin [off-list ref] wrote:
quoted
I just put this togther: https://github.com/sxlijin/xfuncname-test
Try cloning and then for any of config1 thru 3,
$ cp configX .git/config
$ git diff HEAD^ -- test.natvis
On Wed, Feb 8, 2017 at 2:42 PM, Jack Adrian Zappa
[off-list ref] wrote:
quoted
Thanks Samuel,
So, the question is, what is causing this problem on my system?
Anyone have an idea to help diagnose this problem?
On Wed, Feb 8, 2017 at 3:24 PM, Samuel Lijin [off-list ref] wrote:
quoted
On Windows 7, it works for me in both CMD and Git Bash:
$ git --version
git version 2.11.0.windows.3
$ git diff HEAD^ --word-diff
xmlns="http://schemas.microsoft.com/vstudio/debugger/natvis/2010">
<!-- Non-blank line -->
- <Item Name="added var">added_var</Item>
+ <Item Name="added var">added_vars</Item>
<Item Name="var2">var2</Item>
Note the XML namespace in the hunk header. It's put there by the
default rule because "xmlns" starts at the beginning of the line.
Your
diff has nothing there, which means the default rule is not used,
i.e.
your user-defined rule is in effect.
Come to think of it, this line break in the middle of the
AutoVisualizer
tab might have been added by your email client unintentionally, so
that
we use different test files, which then of course results in
different
diffs. Is that the case?
Anyway, if I run the following two commands:
$ git config diff.natvis.xfuncname "^[\t ]*<Type[\t
]+Name=\"([^\"]+)\".*$"
$ echo '*.natvis diff=natvis' >.gitattributes
... then I get this, both on Linux (git version 2.11.1) and on
Windows
(git version 2.11.1.windows.1):
@@ -19,7 +19,7 @@ test <!-- Non-blank line -->- <Item Name="added var">added_var</Item>+ <Item Name="added var">added_vars</Item> <Item Name="var2">var2</Item>
quoted
Just to be sure, I tested your regex and again it didn't work.
At this point I'm out of ideas, sorry. :( The only way I was able to
break it was due to mistyping the extension as "netvis" several times
for some reason.
René
From: Jack Adrian Zappa <hidden> Date: 2017-02-09 00:01:46
Well, it mostly works, but I'm getting some weirdness where it has
grabbed a line at 126 and is using that for the hunk header. Strange
thing is, I move the file to another repository, commit it, make a
change to the fileand do a diff, and it gets the correct hunk header.
I'm at a loss. :(
On Wed, Feb 8, 2017 at 4:12 PM, Jack Adrian Zappa [off-list ref] wrote:
That was it. I have a .gitattributes file in my home directory.
Ahhh, but it's not in my %userprofile% directory, but in my ~
directory.
A bit confusing having 2 home directories. I made a link to my
.gitconfig, but forgot to make a link to my .gitattributes.
Thanks.
A
On Wed, Feb 8, 2017 at 4:05 PM, Samuel Lijin [off-list ref] wrote:
quoted
Double check .gitattributes?
On Feb 8, 2017 2:58 PM, "Jack Adrian Zappa" [off-list ref] wrote:
quoted
Thanks Samuel,
That example showed that there must be something wrong in my .git
directory, because with it, I'm getting the correct output. Moving
the same lines to my .git/config didn't work.
On Wed, Feb 8, 2017 at 3:46 PM, Samuel Lijin [off-list ref] wrote:
quoted
I just put this togther: https://github.com/sxlijin/xfuncname-test
Try cloning and then for any of config1 thru 3,
$ cp configX .git/config
$ git diff HEAD^ -- test.natvis
On Wed, Feb 8, 2017 at 2:42 PM, Jack Adrian Zappa
[off-list ref] wrote:
quoted
Thanks Samuel,
So, the question is, what is causing this problem on my system?
Anyone have an idea to help diagnose this problem?
On Wed, Feb 8, 2017 at 3:24 PM, Samuel Lijin [off-list ref] wrote:
quoted
On Windows 7, it works for me in both CMD and Git Bash:
$ git --version
git version 2.11.0.windows.3
$ git diff HEAD^ --word-diff
xmlns="http://schemas.microsoft.com/vstudio/debugger/natvis/2010">
<!-- Non-blank line -->
- <Item Name="added var">added_var</Item>
+ <Item Name="added var">added_vars</Item>
<Item Name="var2">var2</Item>
Note the XML namespace in the hunk header. It's put there by the
default rule because "xmlns" starts at the beginning of the line.
Your
diff has nothing there, which means the default rule is not used,
i.e.
your user-defined rule is in effect.
Come to think of it, this line break in the middle of the
AutoVisualizer
tab might have been added by your email client unintentionally, so
that
we use different test files, which then of course results in
different
diffs. Is that the case?
Anyway, if I run the following two commands:
$ git config diff.natvis.xfuncname "^[\t ]*<Type[\t
]+Name=\"([^\"]+)\".*$"
$ echo '*.natvis diff=natvis' >.gitattributes
... then I get this, both on Linux (git version 2.11.1) and on
Windows
(git version 2.11.1.windows.1):
@@ -19,7 +19,7 @@ test <!-- Non-blank line -->- <Item Name="added var">added_var</Item>+ <Item Name="added var">added_vars</Item> <Item Name="var2">var2</Item>
quoted
Just to be sure, I tested your regex and again it didn't work.
At this point I'm out of ideas, sorry. :( The only way I was able to
break it was due to mistyping the extension as "netvis" several times
for some reason.
René
From: Jack Adrian Zappa <hidden> Date: 2017-02-09 00:02:05
Tried to copy the .git/config file over to the non-working repository
and it didn't seem to do anything. Could the git database be
partially corrupted?
On Wed, Feb 8, 2017 at 7:00 PM, Jack Adrian Zappa [off-list ref] wrote:
Well, it mostly works, but I'm getting some weirdness where it has
grabbed a line at 126 and is using that for the hunk header. Strange
thing is, I move the file to another repository, commit it, make a
change to the fileand do a diff, and it gets the correct hunk header.
I'm at a loss. :(
On Wed, Feb 8, 2017 at 4:12 PM, Jack Adrian Zappa [off-list ref] wrote:
quoted
That was it. I have a .gitattributes file in my home directory.
Ahhh, but it's not in my %userprofile% directory, but in my ~
directory.
A bit confusing having 2 home directories. I made a link to my
.gitconfig, but forgot to make a link to my .gitattributes.
Thanks.
A
On Wed, Feb 8, 2017 at 4:05 PM, Samuel Lijin [off-list ref] wrote:
quoted
Double check .gitattributes?
On Feb 8, 2017 2:58 PM, "Jack Adrian Zappa" [off-list ref] wrote:
quoted
Thanks Samuel,
That example showed that there must be something wrong in my .git
directory, because with it, I'm getting the correct output. Moving
the same lines to my .git/config didn't work.
On Wed, Feb 8, 2017 at 3:46 PM, Samuel Lijin [off-list ref] wrote:
quoted
I just put this togther: https://github.com/sxlijin/xfuncname-test
Try cloning and then for any of config1 thru 3,
$ cp configX .git/config
$ git diff HEAD^ -- test.natvis
On Wed, Feb 8, 2017 at 2:42 PM, Jack Adrian Zappa
[off-list ref] wrote:
quoted
Thanks Samuel,
So, the question is, what is causing this problem on my system?
Anyone have an idea to help diagnose this problem?
On Wed, Feb 8, 2017 at 3:24 PM, Samuel Lijin [off-list ref] wrote:
quoted
On Windows 7, it works for me in both CMD and Git Bash:
$ git --version
git version 2.11.0.windows.3
$ git diff HEAD^ --word-diff
xmlns="http://schemas.microsoft.com/vstudio/debugger/natvis/2010">
<!-- Non-blank line -->
- <Item Name="added var">added_var</Item>
+ <Item Name="added var">added_vars</Item>
<Item Name="var2">var2</Item>
Note the XML namespace in the hunk header. It's put there by the
default rule because "xmlns" starts at the beginning of the line.
Your
diff has nothing there, which means the default rule is not used,
i.e.
your user-defined rule is in effect.
Come to think of it, this line break in the middle of the
AutoVisualizer
tab might have been added by your email client unintentionally, so
that
we use different test files, which then of course results in
different
diffs. Is that the case?
Anyway, if I run the following two commands:
$ git config diff.natvis.xfuncname "^[\t ]*<Type[\t
]+Name=\"([^\"]+)\".*$"
$ echo '*.natvis diff=natvis' >.gitattributes
... then I get this, both on Linux (git version 2.11.1) and on
Windows
(git version 2.11.1.windows.1):
@@ -19,7 +19,7 @@ test <!-- Non-blank line -->- <Item Name="added var">added_var</Item>+ <Item Name="added var">added_vars</Item> <Item Name="var2">var2</Item>
quoted
Just to be sure, I tested your regex and again it didn't work.
At this point I'm out of ideas, sorry. :( The only way I was able to
break it was due to mistyping the extension as "netvis" several times
for some reason.
René
From: Jack Adrian Zappa <hidden> Date: 2017-02-09 00:10:30
where it has grabbed a line at 126 and is using that for the hunk header.
When I say that, I mean that it is using that line for *every* hunk
header, for every change, regardless if it has passed a hunk head that
it should have matched.
On Wed, Feb 8, 2017 at 7:01 PM, Jack Adrian Zappa [off-list ref] wrote:
Tried to copy the .git/config file over to the non-working repository
and it didn't seem to do anything. Could the git database be
partially corrupted?
On Wed, Feb 8, 2017 at 7:00 PM, Jack Adrian Zappa [off-list ref] wrote:
quoted
Well, it mostly works, but I'm getting some weirdness where it has
grabbed a line at 126 and is using that for the hunk header. Strange
thing is, I move the file to another repository, commit it, make a
change to the fileand do a diff, and it gets the correct hunk header.
I'm at a loss. :(
On Wed, Feb 8, 2017 at 4:12 PM, Jack Adrian Zappa [off-list ref] wrote:
quoted
That was it. I have a .gitattributes file in my home directory.
Ahhh, but it's not in my %userprofile% directory, but in my ~
directory.
A bit confusing having 2 home directories. I made a link to my
.gitconfig, but forgot to make a link to my .gitattributes.
Thanks.
A
On Wed, Feb 8, 2017 at 4:05 PM, Samuel Lijin [off-list ref] wrote:
quoted
Double check .gitattributes?
On Feb 8, 2017 2:58 PM, "Jack Adrian Zappa" [off-list ref] wrote:
quoted
Thanks Samuel,
That example showed that there must be something wrong in my .git
directory, because with it, I'm getting the correct output. Moving
the same lines to my .git/config didn't work.
On Wed, Feb 8, 2017 at 3:46 PM, Samuel Lijin [off-list ref] wrote:
quoted
I just put this togther: https://github.com/sxlijin/xfuncname-test
Try cloning and then for any of config1 thru 3,
$ cp configX .git/config
$ git diff HEAD^ -- test.natvis
On Wed, Feb 8, 2017 at 2:42 PM, Jack Adrian Zappa
[off-list ref] wrote:
quoted
Thanks Samuel,
So, the question is, what is causing this problem on my system?
Anyone have an idea to help diagnose this problem?
On Wed, Feb 8, 2017 at 3:24 PM, Samuel Lijin [off-list ref] wrote:
quoted
On Windows 7, it works for me in both CMD and Git Bash:
$ git --version
git version 2.11.0.windows.3
$ git diff HEAD^ --word-diff
xmlns="http://schemas.microsoft.com/vstudio/debugger/natvis/2010">
<!-- Non-blank line -->
- <Item Name="added var">added_var</Item>
+ <Item Name="added var">added_vars</Item>
<Item Name="var2">var2</Item>
Note the XML namespace in the hunk header. It's put there by the
default rule because "xmlns" starts at the beginning of the line.
Your
diff has nothing there, which means the default rule is not used,
i.e.
your user-defined rule is in effect.
Come to think of it, this line break in the middle of the
AutoVisualizer
tab might have been added by your email client unintentionally, so
that
we use different test files, which then of course results in
different
diffs. Is that the case?
Anyway, if I run the following two commands:
$ git config diff.natvis.xfuncname "^[\t ]*<Type[\t
]+Name=\"([^\"]+)\".*$"
$ echo '*.natvis diff=natvis' >.gitattributes
... then I get this, both on Linux (git version 2.11.1) and on
Windows
(git version 2.11.1.windows.1):
@@ -19,7 +19,7 @@ test <!-- Non-blank line -->- <Item Name="added var">added_var</Item>+ <Item Name="added var">added_vars</Item> <Item Name="var2">var2</Item>
quoted
Just to be sure, I tested your regex and again it didn't work.
At this point I'm out of ideas, sorry. :( The only way I was able to
break it was due to mistyping the extension as "netvis" several times
for some reason.
René
From: René Scharfe <hidden> Date: 2017-02-10 17:59:40
Am 09.02.2017 um 01:10 schrieb Jack Adrian Zappa:
quoted
where it has grabbed a line at 126 and is using that for the hunk header.
When I say that, I mean that it is using that line for *every* hunk
header, for every change, regardless if it has passed a hunk head that
it should have matched.
Strange. That should only happen if no other function lines are
recognized before the changes. You can check if that's the case using
git grep and your xfuncline regex, e.g. like this:
$ git grep -En "^[\t ]*<Type[\t ]+Name=\"([^\"]+)\".*$" *.natvis
And you can check *that* result with regular grep -E or egrep if it
looks funny.
René