I am trying this solution: Can't push to GitHub because of large file which I already deleted
In an elevated cmd (and with Visual Studio closed) I am giving:
git filter-branch --index-filter 'git rm -r --cached --ignore-unmatch <TheFolderIWantToDelete>' HEAD
or:
git filter-branch --index-filter 'git rm -r --cached --ignore-unmatch <TheFolderIWantToDelete>' -f HEAD
and in both cases I get the following error: Access is denied
What exactly is being denied access to? TheFolderIWantToDelete
?
And how can I find out what exactly denies the access?
UPDATE: I also take "Access is denied" when I specify a different existing directory. But when I specify a different non existing directory, I take "The system cannot find the file specified.". So something prevents access to TheFolderIWantToDelete.
CodePudding user response:
This worked (with double quotes): git filter-branch --index-filter "git rm -r --cached --ignore-unmatch ProjectReleases" HEAD