Working with Rider’s built-in terminal

Rider comes with a built-in terminal. It provides a command line right inside of our IDE and lets us do things like running .NET Core commands (for example with Entity Framework core), running Git commands, etc. There’s no switching windows (and mental focus) when we need to perform a quick command line task. In this post, let’s look at a few tips and tricks around Rider’s terminal.

The terminal tool window

We can open the terminal from the View | Tool Windows | Terminal menu (or double-shift and type terminal, or just Ctrl+Alt+1 / ^⌘1). It will open a new tool window running our system’s default shell, pointing at the solution directory. This gives us direct access to all files in our solution. We can run commands against them, switch into a project directory (cd), run dotnet commands, …
Open shell terminal in Rider

The terminal tool window provides history (using the keyboard up/down arrows), and provides the same completion we get in our shell using the Tab key:
Display command history

Now imagine we’re looking at a large output from a command and we want to find a certain string. Using the context menu (or just Ctrl+F) we can search the output:
Find text in terminal window

Perhaps a lesser known feature is that multiple terminal tabs can be opened. Note that we can also give the tabs a name to have a pointer on what we are doing in a given terminal tab:
Multiple terminal tabs

As we’ve seen, Rider’s terminal provides a convenient way to perform command line tasks without having to switch focus. But that’s not all: in a next post, we’ll see how we can use a custom shell. Stay tuned!

Download Rider now and give it a try! We’d love to hear your feedback.

This entry was posted in How-To's and tagged , , . Bookmark the permalink.

4 Responses to Working with Rider’s built-in terminal

  1. Oleg says:

    Is there a way to replace cmd with PowerShell or ConEmu?

    • Maarten Balliauw says:

      Stay tuned for the next post :-)

    • Oleksii Vynnychenko says:

      Sorry, Maarten, I’ll spoil :) Couple of months ago Akinshin gave a hint about that one.

      Oleg, I’ve got Cmder (it’s ConEmu but with couple of plugins and looks a bit fancier). In Rider go to Settings -> Tool -> Terminal and you can specify Shell path, so you can use any underlying console emulator you like: PS, ConEmu, etc. For Cmder for example it’s:
      “cmd.exe” /k “”%CMDER_ROOT%\vendor\init.bat””
      (including all the quotes and specify CMDER_ROOT env variable or substitute with full path)

      It’s quite cool, love it :)

    • Yep, it’s quite easy to replace the shell. Go to Settings → Tools → Terminal and choose another Shell path.

Leave a Reply

Your email address will not be published. Required fields are marked *