I've encountered a critical issue that left me quite concerned. The problem arose when I switched the view to a tree view and selected one of the parent folders, subsequently clicking "Remove File." To my dismay, the entire folder was deleted. Initially, I expected only the files displayed under the tree to be removed, but it turns out that the interface indicates the deletion of the entire main folder.
This situation is particularly hazardous as it's not immediately evident that the intention is to delete the entire folder, including elements not visible in Git.
Hi @refael
Welcome to the Atlassian community!
Is this still an open question for you, or did you manage to sort it out?
In case it helps anyone landing here later, what you saw is expected behavior, not a bug. When you select a parent folder in tree view and choose Remove, Sourcetree runs a git rm on all tracked files under that folder, staging them for deletion and removing them from disk. If you did this by accident, you can usually recover with git checkout . or git reset --hard HEAD before committing, since the files still exist in your last commit.
Cheers, Martin
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.