Git Gui Here 右鍵菜單, 加Shift才顯示


被流氓軟件惡心到了,想刪除它的右鍵菜單,沒想到順便學習了一下windows中右鍵菜單的知識

右鍵菜單在注冊表中 可能出現在這 三個位置

HKEY_CLASSES_ROOT\LibraryFolder\background\shell
HKEY_CLASSES_ROOT\Directory\Background\shell
HKEY_CLASSES_ROOT\Directory\shell
這三個具體意思 沒查到什么意思,不過實驗了下, LibraryFolder 猜是指庫文件夾, 另兩個是指目錄中的shell(選擇文件時右鍵),Background(空白地方右擊)

Extended 表示這條命名是"shift"與右鍵同時按下時才啟用

所以我進行了幾處改動

所有的"Git Bash Here""Git Gui Here'都要shift同時按下才顯示
"在此處打開命名窗口"的右鍵菜單,添加滿三個位置,保證庫文件目錄,桌面等位置都能調出它.
Windows Registry Editor Version 5.00

;Extended 表示 shift+右鍵 才顯示出該命名
; 在庫文件 內 也加上 "在此處打開命名窗口" 的右鍵菜單命名. 
[HKEY_CLASSES_ROOT\LibraryFolder\background\shell\cmd]
@="@shell32.dll,-8506"
"Extended"=""
"NoWorkingDirectory"=""

[HKEY_CLASSES_ROOT\LibraryFolder\background\shell\cmd\command]
@="cmd.exe /s /k pushd \"%V\""


;git-gui
[HKEY_CLASSES_ROOT\LibraryFolder\background\shell\git_gui]
@="Git &GUI Here"
"Icon"="C:\\Program Files\\Git\\cmd\\git-gui.exe"
"Extended"=""

[HKEY_CLASSES_ROOT\LibraryFolder\background\shell\git_gui\command]
@="\"C:\\Program Files\\Git\\cmd\\git-gui.exe\" \"--working-dir\" \"%v.\""

;git_shell
[HKEY_CLASSES_ROOT\LibraryFolder\background\shell\git_shell]
@="Git Ba&sh Here"
"Icon"="C:\\Program Files\\Git\\git-bash.exe"
"Extended"=""

[HKEY_CLASSES_ROOT\LibraryFolder\background\shell\git_shell\command]
@="\"C:\\Program Files\\Git\\git-bash.exe\" \"--cd=%v.\""

;git_gui
[HKEY_CLASSES_ROOT\Directory\Background\shell\git_gui]
@="Git &GUI Here"
"Icon"="C:\\Program Files\\Git\\cmd\\git-gui.exe"
"Extended"=""

[HKEY_CLASSES_ROOT\Directory\Background\shell\git_gui\command]
@="\"C:\\Program Files\\Git\\cmd\\git-gui.exe\" \"--working-dir\" \"%v.\""

;git_shell
[HKEY_CLASSES_ROOT\Directory\Background\shell\git_shell]
@="Git Ba&sh Here"
"Icon"="C:\\Program Files\\Git\\git-bash.exe"
"Extended"=""

[HKEY_CLASSES_ROOT\Directory\Background\shell\git_shell\command]
@="\"C:\\Program Files\\Git\\git-bash.exe\" \"--cd=%v.\""

;git_gui
[HKEY_CLASSES_ROOT\Directory\shell\git_gui]
@="Git &GUI Here"
"Icon"="C:\\Program Files\\Git\\cmd\\git-gui.exe"
"Extended"=""

[HKEY_CLASSES_ROOT\Directory\shell\git_gui\command]
@="\"C:\\Program Files\\Git\\cmd\\git-gui.exe\" \"--working-dir\" \"%1\""

;git_shell
[HKEY_CLASSES_ROOT\Directory\shell\git_shell]
@="Git Ba&sh Here"
"Icon"="C:\\Program Files\\Git\\git-bash.exe"
"Extended"=""

[HKEY_CLASSES_ROOT\Directory\shell\git_shell\command]
@="\"C:\\Program Files\\Git\\git-bash.exe\" \"--cd=%1\""


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM