使用brew uninstall --force node报错:无名为‘–force’的可用公式
解决brew卸载node时的"No available formula with the name '–force'"错误
问题原因
你输入的命令里,–force用的是中文全角破折号,brew误将它识别为要卸载的软件包名称,而非命令参数,因此抛出错误。
解决步骤
- 执行正确的卸载命令,使用英文半角双短横线的
--force参数:brew uninstall --force node - (可选)如果需要彻底清理node相关残留文件,可额外执行:
rm -rf /usr/local/lib/node_modules rm -rf ~/.npm
内容的提问来源于stack exchange,提问作者Huckleberry Carignan
相关产品推荐
相关产品推荐

