-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Labels
bugSomething isn't workingSomething isn't workingquestionFurther information is requestedFurther information is requested
Description
Describe the bug
Title
To Reproduce
Steps to reproduce the behavior:
- Run
git branch -d old_branchorgit branch -D old_branchfrom git root or from the worktree directory. - This doesn't seem to delete the branch and worktree from the git cache, doing
git checkout old_branchre-creates the worktree directory with the files of the 'deleted' branch.
Expected behavior
git checkout old_branch should raise an error after such branch has been deleted.
Screenshots
N/A
Desktop (please complete the following information):
- OS: Linux Mint 20, but tested on Windows 10 and Windows 11, too.
- Git version: 2.25.1
- Shell: Bash 5.0.16
- Repository version: v1.1.0
Additional context
git branch -d/-D old_branch does indeed delete the worktree directory, but it's kept in the cache.
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingquestionFurther information is requestedFurther information is requested
Projects
Status
To do