Open File With Navigation Bar

Open a file somewhere in the project tree using the keyboard and Navigation Bar.

If you've closed the Project tool window and hidden the Navigation Bar, you need a way to open file that's keyboard centric and doesn't disrupt your flow. Usually, the fastest way to open a file is the various search options (Recent Files, Navigate to File, etc.) But other times, you want to browse instead of search.

As shown previously, use the Navigation Bar to select a file:

  • Activate the Navigation Bar with Navigate | Jump to Navigation Bar ⌘↑ (macOS) / Alt+Home (Windows/Linux)

  • Use the cursor keys to get to the target directory

  • Speed search to select the file

Once selected in the Navigation Bar, press (macOS) / Enter (Windows/Linux) and the IDE will open your file. Clicking with the mouse also works.

As a note, this is a very common pattern for jumping to a file in the current directory. In this case, you don't have to press (macOS) / Up Arrow (Windows/Linux) to go up to the directory. Even though the current file selected, you can still press (macOS) / Down Arrow (Windows/Linux) or better still, just start speed searching.

Opening the file isn't the only operation you can do on a selected Navigation Bar item. You can Refactor This, delete...basically, anything you could do when you click on the file in the Project Tool. We'll see two examples in subsequent tips.


Related Resources

How to Quickly Jump to Recent Files in any JetBrains IDE
Are you tired of hunting for that crucial file buried in your project? Say goodbye to the hassle with these IDE shortcuts and tips. Jump to recent files effortlessly in JetBrains IDEs like IntelliJ IDEA, PyCharm, PhpStorm, WebStorm, GoLand, CLion, RubyMine, and more!
Find In Path With Navigation Bar
Use keyboard and Navigation Bar to find files under a path.
Create New File With Navigation Bar
Activate the Navigation Bar and create a new file somewhere in the project tree.