Dnv.ReSharper.Plugins.LowerSecond

Created: 2014-05-19 11:57
Updated: 2014-05-22 05:05
c#

README.md

Dnv.ReSharper.Plugins.LowerSecond

Very small ReSharper 6.1 plugin. Introduces a 2 new macro:

  1. Value of another variable with the first character replaced with '_' and second character in lower case. Example: IApplicationSettings => _applicationSettings
  2. Value of another variable with the first character removed and second character in lower case. Example: IApplicationSettings => applicationSettings

#Installation

  1. Build the solution. You can choose not to build Tests project by right clicking on it and selecting "Unload Project".
  2. Copy Dnv.ReSharper.Plugins.LowerSecond.dll to c:\Program Files (x86)\JetBrains\ReSharper\v6.1\Bin\Plugins

#Usage

Create new live template. In VS main menu: ReSharper->Templates Explorer, then in "Live Templates" tab press "New Template" and fill the text like in the picture below:

Select value "Guess type expected at this point" for $Interface$ and "Value of another variable with the first character replaced with '' and second character in lower case" for $mockName$.

In code editor type moqf

then presss enter and start typing the interface name in the template specification, you will get field automatically renamed:

Cookies help us deliver our services. By using our services, you agree to our use of cookies Learn more