Cannot update while running on a read-only volume. The application is on a read-only volume. Please

最近vue项目打包扔到线上发现更改的东西显示空白页面
然后就猜测可能是vscode版本的问题,这个时候我去更新版本突然发现以下问题:
Cannot update while running on a read-only volume. The application is on a read-only volume. Please move the application and try again. If you’re on macOS Sierra or later, you’ll need to move the application out of the Downloads directory. See this link for more information.

大概意思就是说我是只读权限,然后官方说执行以下两个指令就可以了

sudo chown -R $USER ~/Library/Caches/com.microsoft.VSCode.ShipIt

xattr -dr com.apple.quarantine /Applications/Visual\ Studio\ Code.app

第一行代码会让你输入密码来进行操作,密码输入的时候是不显示的大胆输入完回车就行
第二行代码/Applications/Visual\ Studio\ Code.app这个是代表你的vscode的程序路径,mac版本可能不太好找路径,推荐下载一个超级右键软件然后在应用程序中找到vscode之后直接右键去copy路径就可以了
在这里插入图片描述
最后再去打包发现没问题

评论 4
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值