My source control tab looks like this:
If I type git status
, it looks like this:
I thought this could be because of whitespace differences, but I turned on "render whitespace" in my settings, and I don't see any changes in the files that are marked as modified. Here's an example:
Why is there a difference between my commandline and what Visual Studio Code is showing? This is making me lose confidence that I can trust any commit I make in Visual Studio Code. For what it's worth, I have autosave turned on, so I don't think that it's a failure on my part to save a modification.
If I commit everything from the command line, and then it says there are no changes, Visual Studio still shows about 12 files changed in the source control tab.
I found the cause:
I decided to commit from Visual Studio Code, and then go to the command line and inspect that commit. Here's what it says:
.eslintrc.json changed file mode from 100755 to 100644
.gitignore changed file mode from 100755 to 100644
package.json changed file mode from 100755 to 100644
src/electron.ts changed file mode from 100755 to 100644
src/index.css changed file mode from 100755 to 100644
src/index.html changed file mode from 100755 to 100644
src/renderer.ts changed file mode from 100755 to 100644
tsconfig.json changed file mode from 100755 to 100644
webpack.main.config.js changed file mode from 100755 to 100644
webpack.plugins.js changed file mode from 100755 to 100644
webpack.renderer.config.js changed file mode from 100755 to 100644
webpack.rules.js changed file mode from 100755 to 100644
Now that Visual Studio Code says there are no changes, my commandline says all these files have changed. It seems like they are both fighting to change the modes of these files back and forth. How do I get them to agree so they don't consider these file modes as changes?