该错误为当前用户没有权限对文件作修改
输入
:w !sudo tee %
:w – write
!sudo – call shell sudo command
tee – the output of write (:w) command is redirected using tee
% – current file name
该错误为当前用户没有权限对文件作修改
输入
:w !sudo tee %
:w – write
!sudo – call shell sudo command
tee – the output of write (:w) command is redirected using tee
% – current file name