Comments (9)
@laurentkempe Cool. As stated here, if I add .gitattributes
file with the line * text=auto
or execute a command git config --global core.autocrlf true
, the issue is gone. Thank you for the hint!
from gitdiffmargin.
Hello.
I'm having this issue today 1 march 2019, using the newest version 3.9.2.42 updated automatically by Visual Studio 2017.
Microsoft Visual Studio Professional 2017
Version 15.9.7
VisualStudio.15.Release/15.9.7+28307.423
Microsoft .NET Framework
Version 4.7.03056
Installed Version: Professional
The only line I have changed in the file is the one marked in orange.
According to git, only that line is changed:
I have seen it a few times recently, but cannot remember if it begun today or earlier.
from gitdiffmargin.
I've never seen anything like this. My guess is there's another extension which is changing the line endings of the file behind the scenes.
Off the top of my head I'm not quite sure how to debug this. Any ideas @laurentkempe?
from gitdiffmargin.
Actually, another possibility is the path to the file (including the file name) within the project file in Visual Studio differ from the file on disk by case only.
❓ Try restarting Visual Studio and opening this file without opening the solution (just open the file by itself in a fresh copy of Visual Studio. Does the problem still occur? If so, make sure that the path to the file on your drive (Windows is case-insensitive) matches the path to this file within the Git repository (which is case-sensitive), and try again.
from gitdiffmargin.
I was also thinking of the line endings. I currently do not have the C++ installed to try reproduce it, will try to install it to have a look
from gitdiffmargin.
Ok, that's what I was able to find out:
- There is no interference with any other extensions: I disabled all of them
- There is no difference whether I open the file as a part of a solution or as an independent file
- The bug is reproduced in both Visual Studio 2013 and 2015. However, on Visual Studio 2013 on a different computer with the similar environment I do not experience this bug.
- If I change line endings from Windows style to Unix style, the bug disappears
So it seems like your guess was right in the spot!
from gitdiffmargin.
I've had exactly the same problem, I only see the real diffs if I change the line ending from Windows to Unix style as @mmatrosov points out (File -> Advanced Save Options...).
The only difference I have is that I see this with a .cs project, not a .cpp one.
But is there a way to make GitDiffMargin work without doing this?
from gitdiffmargin.
@mattwarren Could it be your .gitattributes that set the file to Unix?
from gitdiffmargin.
@laurentkempe
I got rid of the problem mentioned above by reverting to v3.9.0
If I install the one labeled security fix, the problem comes back.
from gitdiffmargin.
Related Issues (20)
- Marketplace description says support is up to VS 2019 Preview HOT 3
- Icons are missing from the popup window HOT 11
- VS crashing after update to 3.10.3 HOT 5
- Failed to install the extension (VS 2017, VS 2019) HOT 8
- Issue publishing version for Visual Studio 2022 to Visual Studio Marketplace HOT 4
- Extension fails to load with error System.IO.FileNotFoundException HOT 6
- Missing icons HOT 5
- Icons are invisible on dark theme HOT 2
- It's annoying behaviour observed with Quick Search
- Extension not activated when opened solution not having any opened documents
- Extension stopped working until disabling and reenabling (persisting through restarts) HOT 6
- CRLF mismatch - whole file shown as modified HOT 1
- VS 2019 Installation Error HOT 3
- Try dogged HOT 1
- Installer size
- Next/Previous function in tool bar and assigned to hot keys don't work HOT 22
- Not working in VS 2022 (Version 17.1.0) HOT 2
- Not working Visual Studio 2022 17.2.2 HOT 7
- Keyboard shortcuts for GitDiffMargin.NextChange & GitDiffMarginPreviousChange don't work HOT 2
- Insert "manual" into addon description.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gitdiffmargin.