Development environment advices

Some advices on how to set up your development environment for Orchard Development.

Software to install

Below you can find pieces of software that you should install for the best Orchard developer experience.

Make sure to always run Visual Studio as an administrator!

Visual Studio tips

  • Use code snippets; try out the ones in this package too that specifically aid Orchard development.
  • Use keyboard shortcuts. The most useful ones are:
    • F5: start with debugging
    • Ctrl+F5: start without debugging
    • F6: build
    • F10: run to the next line, when debugging
    • F11: step into the code on the current line (e.g. if the current line is a method call this will forward you to the body of the method), when debugging
    • Ctrl+F10: run to the cursor, when debugging
    • Ctrl+.: opens the Smart Tag
    • Ctrl+Shift+Enter: adds a new line below the current line
    • F9: places a breakpoint on the current line
    • Ctrl+K, Ctrl+D: format document
    • Ctrl+K, Ctrl+C: comment selection
    • Ctrl+K, Ctrl+U: uncomment selection
    • Ctrl+,: opens the Navigate To windows (i.e. search for types or members)
    • Ctrl+D, Ctrl+E or Ctrl+Alt+E: opens the Exceptions configuration page. Tick Common Language Runtime Exceptions - Thrown to see all exceptions, even if they're caught.
    • Ctrl+Q to access the Quick Launch bar
    • Shift+Del: delete line
    • You may want to set up Ctrl+W for closing the current file for the File.Close command and Ctrl+Shift+T for Edit.UndoClose (only available if PowerCommands is installed).
  • You may want to always run VS as an administrator. This will simplify debugging web apps running in IIS since you can only attach a debugger to the IIS worker process if VS is run as an administrator.

Mercurial and TortoiseHg tips

  • Interact with Mercurial through the TortoiseHg Workbench. You can add a cloned repository to the Workbench by opening it from the repository folder: right click on the folder and select the Workbench.
  • Use groups in the Repository Registry to group your repositories.
  • See the mercurial.ini in file in this package that you can use to initialize your Mercurial instance quickly with some useful settings. You can open your mercurial.ini file quickly from inside TortoiseHg by going to File/Settings/Edit File.
  • .hgignore files (drop into the repositories' folders and rename to .hgignore):

This page is part of the Orchard Dojo Library!

This page and many others here are part of the open source, portable package of Orchard goodies: the Orchard Dojo Library. The Library is freely accessible by anyone; just go to its repository to download its full content (you can even download the textual content of the Library as a big concatenated document in HTML), file issues or fork it! You can even edit it online on Bitbucket, just click on the Edit link in the upper right corner!