进入anaconda目录(为了防止删掉其他无辜文件),然后执行
find '.' -name "*xxx*.egg-info" -exec rm -rf {} \;
例如对于问题
ERROR: Cannot uninstall ‘certifi’. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.
在shell中执行
find '.' -name "*certifi*.egg-info" -exec rm -rf {} \;