All docs
V20.2
20.2
20.1
The page you are viewing does not exist in version 20.1. This link will take you to the root page.
19.2
The page you are viewing does not exist in version 19.2. This link will take you to the root page.
19.1
The page you are viewing does not exist in version 19.1. This link will take you to the root page.
18.2
The page you are viewing does not exist in version 18.2. This link will take you to the root page.
18.1
The page you are viewing does not exist in version 18.1. This link will take you to the root page.
17.2
The page you are viewing does not exist in version 17.2. This link will take you to the root page.

How to: Share CodeRush Settings with a Team

  • 2 minutes to read

The Options Layers feature allows you to share CodeRush options between developers in your team. This example shows how to share the "h1" code template defined for your solution.

Create a Template

  • Open your solution in Visual Studio.

  • Select the "CodeRush | Code Templates‚Ķ" item in Visual Studio's menu to open the templates options page.

    Code Templates Page

  • Click the "New Category" toolbar button.

    Click New Category

  • In the "New Category" dialog, enter the "Team Templates" category name, check the "Make this a top-level folder" check box, and click OK to create the "Team templates" category.

    Specify Category

  • Right-click the newly added category and select "New Template"

    Right Click Template Category

  • In the "New Template" dialog, enter the "t1" template name and click OK.

    Template Dialog

  • Select the "t1" template and enter the following code in the expansion editor:

    public class MyTeamTemplate { }  
    

    You can enter your own template text in the expansion editor. For more information on custom templates creation, refer to the following documentation section: Custom Templates Creation.

Save New Template Category to the Solution Team Layer

Click the "Save To" drop-down button at the bottom of the options page and select "Solution Team Options".

Template Dialog

CodeRush saves the newly added template category to the solution team options layer and closes the Templates options page.

When you open your solution, CodeRush loads the newly created template. You can expand this template in the code editor.

CodeRush stores settings of the solution team options layer inside the (.cr\team) solution directory. The (.cr\personal) solution directory contains your preferences for the current solution.

To share the settings with you team:

  • Correct .gitignore or .hgignore files if you use git or mercurial as the source control to exclude the ".cr\personal" folder from it and to include the ".cr\team" folder.

  • Commit files inside the ".cr\team" folder to the source control. These files will be available to all users in your team.

For more information on Options Layers, refer to the Options Layers topic.