Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @echo off
- SET stPath=C:\Program Files\Sublime Text 3\sublime_text.exe
- SET entryName=Open with Sublime Text 3
- SET menuText=Open with Sublime Text 3
- rem add it for all file types
- @reg add "HKEY_CLASSES_ROOT\*\shell\%entryName%" /t REG_SZ /v "" /d "%menuText%" /f
- @reg add "HKEY_CLASSES_ROOT\*\shell\%entryName%" /t REG_EXPAND_SZ /v "Icon" /d "%stPath%,0" /f
- @reg add "HKEY_CLASSES_ROOT\*\shell\%entryName%\command" /t REG_SZ /v "" /d "%stPath% \"%%1\"" /f
- rem add it for folders
- @reg add "HKEY_CLASSES_ROOT\Folder\shell\%entryName%" /t REG_SZ /v "" /d "%menuText%" /f
- @reg add "HKEY_CLASSES_ROOT\Folder\shell\%entryName%" /t REG_EXPAND_SZ /v "Icon" /d "%stPath%,0" /f
- @reg add "HKEY_CLASSES_ROOT\Folder\shell\%entryName%\command" /t REG_SZ /v "" /d "%stPath% \"%%1\"" /f
- pause
Add Comment
Please, Sign In to add comment