如何用鼠标右按钮直接以 Root 身份开启文件?

gedit $HOME/.gnome2/nautilus-scripts/Open as root

# 在新增的文件内加入下面这几行

for uri in $NAUTILUS_SCRIPT_SELECTED_URIS; do
    gnome-sudo "gnome-open $uri" &
done

# 保存编辑过的文件 (范例)
#

chmod +x $HOME/.gnome2/nautilus-scripts/Open as root

#

鼠标右按钮点击文件 -> Scripts -> Open as root

1 thought on “如何用鼠标右按钮直接以 Root 身份开启文件?

Leave a Reply

Your email address will not be published. Required fields are marked *