microsoft / microsoft/VFSForGit

Mac: git's bash integration scripts report modifications when there are none

Open
#707 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

domain: user-mode platform: macOS priority: dogfood priority: mac-next
Dominant language
C#
Stars
6.1k
Forks
474
Avg merge
2d 4h
Merged PRs (30d)
8

Description

  1. Open Terminal
  2. Clone\mount a VFS4G repo
  3. Run the following commands:
source /Applications/Xcode.app/Contents/Developer/usr/share/git-core/git-completion.bash
source /Applications/Xcode.app/Contents/Developer/usr/share/git-core/git-prompt.sh
export GIT_PS1_SHOWDIRTYSTATE=true
export PS1='\n[\h:\w$(__git_ps1)]\n \u\$ '
  1. Navigate to freshly cloned repo

Observe: Bash prompt displays a * in the prompt:

[GVFSs-MBP:~/GVFSTest/src (master *)]

Indicating that it thinks there are modifications.

Other thoughts

The scripts that ship with git appear to be using git diff --no-ext-diff --quiet and it is returning a non-zero exit code.

On my machine git diff shows no differences but git diff --raw shows differences in .gitattributes (it could be related to timestamps?)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue in Terminal by sourcing git-completion.bash and git-prompt.sh, setting GIT_PS1_SHOWDIRTYSTATE, and entering a freshly cloned VFS4G repository. Compare git diff with git diff --raw, focusing on the reported .gitattributes difference and the prompt's cleanliness check. Done means an unchanged repository no longer displays * in the prompt.

Written by the indexing model from the issue text.

Assessment

Tech stack
bash, git
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.