I made some changes in my source file. When i try to see the diff using
git diff src/core/src/authentication.rs
The diff on the console is having ^M
appended to all the lines I edited.
+ Some(b) => {^M
+ Ok(b)^M
+ }^M
+ }^M
}
I checked out in notepad to see if I can see something there and clean it up but was not visible there with any encoding I tried. I read somewhere that it is a \r
but not sure. Could not replace/find it in vim.
However this does not happen in all the files I see a diff
for. Why is this happening? I guess this is not part of my source code and only something to do with git.
Edit: I use vim as my editor.