Advertisement
Guest User

Untitled

a guest
Oct 22nd, 2016
61
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.97 KB | None | 0 0
  1. @echo off
  2. SET AppKey=SublimeText3
  3. SET AppTitle=Open with Sublime Text 3
  4. SET AppPath=C:\Program Files\Sublime Text 3\sublime_text.exe
  5. SET AppIcon=%AppPath%,0
  6.  
  7. rem add it for all file types
  8. REG ADD "HKEY_CLASSES_ROOT\*\shell\%AppKey%" /ve /f /d "%AppTitle%"
  9. REG ADD "HKEY_CLASSES_ROOT\*\shell\%AppKey%" /v "Icon" /f /d "%AppIcon%"
  10. REG ADD "HKEY_CLASSES_ROOT\*\shell\%AppKey%\command" /ve /f /d "%AppPath% \"%%1\""
  11.  
  12. rem add it for folders
  13. REG ADD "HKEY_CLASSES_ROOT\Directory\shell\%AppKey%" /ve /f /d "%AppTitle%"
  14. REG ADD "HKEY_CLASSES_ROOT\Directory\shell\%AppKey%" /v "Icon" /f /d "%AppIcon%"
  15. REG ADD "HKEY_CLASSES_ROOT\Directory\shell\%AppKey%\command" /ve /f /d "%AppPath% \"%%v\""
  16.  
  17. rem add it for current folder
  18. REG ADD "HKEY_CLASSES_ROOT\Directory\Background\shell\%AppKey%" /ve /f /d "%AppTitle%"
  19. REG ADD "HKEY_CLASSES_ROOT\Directory\Background\shell\%AppKey%" /v "Icon" /f /d "%AppIcon%"
  20. REG ADD "HKEY_CLASSES_ROOT\Directory\Background\shell\%AppKey%\command" /ve /f /d "%AppPath% \"%%v\""
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement