Easily open Command Window in Visual Studio for Sitecore gulp deploys

Here’s a simple productivity tip that I like to use when developing with Sitecore. When we build projects using the Helix model, I use gulp to run the builds. This is what Sitecore provides as an example in the Habitat project. So, let’s make this easy.

1. Open External Tools

2. Add a new external tool.

I called mine, “Launch Windows Command Line”

Pass in these arguments:

Command: cmd.exe (this could be any application but in this case, we want the command window)

Arguments: cd $(SolutionDir) (this is what we are passing into the command window.

Initial Directory: $(SolutionDir)

3. Head over to the Tools -> Options menu

4. Configure the Tools.ExternalCommad1 with a short cut key. I used Ctrl-W, Ctrl-W. You could have left the “Launch Windows Command Line” in position 4, but then you’d have to set the Tools.ExternalCommand4 shortcut.

After configuring, head over to the solution window and type Ctrl-W, Ctrl-W or whatever you used and your command window should pop up in the directory, all ready for you to type “gulp default”!

About Phil Paris

Hi, my name is Phil Paris and I’m a Sitecore Architect and general Sitecore enthusiast. I’ve been working with Sitecore since 2013. Through this blog I will be sharing Sitecore insights, tips and tricks, best practices and general knowledge with the hopes to further the community at large. Please feel free to reach out to me at any time!

View all posts by Phil Paris →