To get BareGrep on the Windoze Explorer context menu…
Copy the following into a file called <BareGrep_Here.reg>. This assumes that <BareGrep.exe> is copied into <C:\Program Files\>.
Windows Registry Editor Version 5.00 [HKEY_CLASSES_ROOT\Directory\shell\BareGrepHere] @="BareGrep here" [HKEY_CLASSES_ROOT\Directory\shell\BareGrepHere\command] @="\"C:\\Program Files\\BareGrep.exe\" --no-regex --directory \"%1\"" [HKEY_CLASSES_ROOT\Drive\shell\BareGrepHere] @="BareGrep here" [HKEY_CLASSES_ROOT\Drive\shell\BareGrepHere\command] @="\"C:\\Program Files\\BareGrep.exe\" --no-regex --directory \"%1\"" [HKEY_CLASSES_ROOT\*\shell\BareGrepHere] @="BareGrep here (containing folder)" [HKEY_CLASSES_ROOT\*\shell\BareGrepHere\command] @="\"C:\\Program Files\\BareGrep.exe\" --no-regex --directory \"%1\\..\"" [HKEY_CLASSES_ROOT\*\shell\BareGrepThis] @="BareGrep this" [HKEY_CLASSES_ROOT\*\shell\BareGrepThis\command] @="\"C:\\Program Files\\BareGrep.exe\" --no-regex \"%1\""
Then double-click on the file to import these setings into your registry.
Any suggestions for improvements welcome. A couple of minor glitches with these settings:
- When BareGrep is launched from the context menu of a file via “BareGrep this”, the full path of the file appears in the Files field, even though the path to the containing directory appears in the Folder field.
- When BareGrep is launched from the context menu of a file via “BareGrep here (containing folder)”, the un-normalised path of the directory containing the file appears in the Folder field, and the search doesn’t start until something is typed or clicked. (The path then gets normalised.)