

When VSCode runs certain git operations while files are locked, it corrupts the cached index because GIT has to convert line endings from CRLF to LF when it's storing the files in its database. There seems to be a separate issue that's caused by this issue. because they don't get cached in the git index. This can get very expensive since on every git view refresh these hashes would be recomputed. The consequence would be that touched files would appear in the git viewlet, unless VSCode does the hashing itself or calls git to do it. Git diff-index HEAD will incorrectly report it as modified since it doesn't hash the file but merely looks at the last modified timestamp. The reason why git status writes to the index, though, is very important: if you touch a file without modifying its contents, git status will hash the file, cache it in the index and not report it as modified. git diff-index -cached HEAD, for the changes between the index and HEAD.git diff-index HEAD, for the changes between the working tree and HEAD.git ls-files -others -exclude-standard, for untracked files.There are a few commands which would give us the same results: We could avoid calling git status since that writes to the index. No changes added to commit (use "git add" and/or "git commit -a")ĭropped (90803eefd2da3da61892b8c7d1e2ae898f3fd92d) " to discard changes in working directory) (use "git push" to publish your local commits) Your branch is ahead of 'origin/master' by 1 commit. Lib/server/dbal/dbal-base.ts: Permission deniedįirst, rewinding head to replay your work on top of it.Īpplying: Issue #6272: webapp: bugfix after enum rewrite. Saved working directory and index state WIP on master: 2811dac Issue #6272: webapp: bugfix after enum rewrite.Įrror: unable to create file lib/server/dbal/dbal-base.ts (Permission denied)įatal: Could not reset index file to revision 'HEAD'.
