Git branch -d <BRANCH>: Fatal - Could not find commit object for HEAD
Make sure capitol D used in the command, in which case you should enter git branch -D <branch_name> . Please note: this will only remove the branch from your local computer.
If you are trying to remove the remote branch, type git push origin :<branch_name> (don't forget to add a colon)
This only happens when the default branch (which the HEAD branch points to in an empty repository folder - usually master ) does not exist locally. If it exists, you can delete a branch with branch -d even from an empty repository folder (-d if it is merged).
If you work with git working trees, the execution of a command from the working tree may be successful (the same condition must be met as for the HEAD of the working tree)