linux 命令行管理员身份运行,任意位置以管理员身份打开CMD(命令提示符)
關于CMD這個東西,windows和linux還是有很大差別的,linux系統下可以在任意位置右鍵選擇在當前文件夾打開終端,而windows沒有這個功能,每次打開都是默認的位置,然后不停的cd。為了提升效率,添加以管理員身份在當前文件夾打開CMD至右鍵。
一、添加至右鍵
1.新建文本文檔,將下列腳本復制進去
Windows Registry Editor Version 5.00
; Created by: Shawn Brink
; http://www.sevenforums.com
; Tutorial: http://www.sevenforums.com/tutorials/47415-open-command-window-here-administrator.html
[-HKEY_CLASSES_ROOT\Directory\shell\runas]
[HKEY_CLASSES_ROOT\Directory\shell\runas]
@="xxx"? ? ? ? ? ? ?#名稱隨意,此三處最好一致
"HasLUAShield"=""
[HKEY_CLASSES_ROOT\Directory\shell\runas\command]
@="cmd.exe /s /k pushd \"%V\""
[-HKEY_CLASSES_ROOT\Directory\Background\shell\runas]
[HKEY_CLASSES_ROOT\Directory\Background\shell\runas]
@="xxx"? ? ? ? ? ?#同上,此三處最好一致
"HasLUAShield"=""
[HKEY_CLASSES_ROOT\Directory\Background\shell\runas\command]
@="cmd.exe /s /k pushd \"%V\""
[-HKEY_CLASSES_ROOT\Drive\shell\runas]
[HKEY_CLASSES_ROOT\Drive\shell\runas]
@="xxx"? ? ? ? ? ?#同上,此三處最好一致
"HasLUAShield"=""
[HKEY_CLASSES_ROOT\Drive\shell\runas\command]
@="cmd.exe /s /k pushd \"%V\""
2.名稱隨意,將拓展名txt改為reg,雙擊運行
二、從右鍵刪除
1.新建文本文檔,將下列腳本復制進去
Windows Registry Editor Version 5.00
; Created by: Shawn Brink
; http://www.sevenforums.com
; Tutorial: http://www.sevenforums.com/tutorials/47415-open-command-window-here-administrator.html
[-HKEY_CLASSES_ROOT\Directory\shell\runas]
[-HKEY_CLASSES_ROOT\Directory\Background\shell\runas]
[-HKEY_CLASSES_ROOT\Drive\shell\runas]
2.名稱隨意,將拓展名txt改為reg,雙擊運行
(圖片就不放了,懶得截圖,反正就是右鍵沒有了那個打開CMD的選項)
總結
以上是生活随笔為你收集整理的linux 命令行管理员身份运行,任意位置以管理员身份打开CMD(命令提示符)的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 宝宝的眼睛与微量元素的关系
- 下一篇: linux打不开vlc怎么办下面是解决方