Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How do I configure the Google Chrome / Chromium address bar to perform a search instead of trying to access a file on the local file system? I would like to be able to enter a file name such as /etc/hosts or /Windows/System32/Drivers/etc/hosts in the address bar and to see Google search results for those file names similar to what I would see if I searched for the file names using something like https://www.google.com/#q=/etc/hosts

I am able to disable the file scheme using either of the following policy settings:

"DisabledSchemes": ["file"],

Which has been deprecated in favor of:

"URLBlacklist": ["file://"],

But in either case Google Chrome / Chromium continues to auto-detect that a file name was entered, automatically prepends the file scheme to the file name, and then reports that the webpage is blocked.

share|improve this question
    
Do you have an example of a filename that it does that for? I don't think what you're seeing is normal behavior. – Steve Campbell Mar 6 '15 at 22:14
    
Thanks for the comment! Knowing that the search was possible on some operating systems clued me in to using backslashes instead of forward slashes in the path. – Daniel Kauffman Mar 9 '15 at 16:41
up vote 1 down vote accepted

Currently, a workaround is to use backslashes \ instead of forward slashes / in the path.

For example, in the address bar, instead of entering /etc/hosts or /Windows/System32/Drivers/etc/hosts search for \etc\hosts or \Windows\System32\Drivers\etc\hosts.

This works even when referring to file systems (such as those found on OS X and Linux) that use forward slashes instead of backslashes.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .