Skip to content

git clean -fd does not clean Junctions/Symlinks #973

Description

@larsxschneider

#607 might be related.

Setup

git version 2.11.0.rc3.windows.1
sizeof-long: 4
machine: x86_64

(I got the same behaivor for git 2.8 / 2.9 / 2.10 on Windows)

Microsoft Windows [Version 6.3.9600]

Details

Consider this test script in CMD:

git --version
git init .
git config --local core.symlinks true   # I tried true/false here 
echo $null >> test1.txt
git add .
git commit -m "test"
mklink /J link C:
git clean -fd
git status

I expect git clean to remove the unstaged Junction but instead I get the following:

On branch master
Untracked files:
  (use "git add <file>..." to include in what will be committed)

        link/

nothing added to commit but untracked files present (use "git add" to track)

Is this behavior by intention or a bug?

Thanks,
Lars

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions