How to set assignment format?

Hi,

I have a huge codebase that has thousands of assignments in an 'var x=new X();' format, rather than a 'var x = new X();'.  Its just missing the space on either side of the '=' which is recommended according to our coding standards.

How do I edit the resharper settings so that when I do a code cleanup it automatically inserts the spaces?

Thanks!

1 comment

ReSharper => Options.
Under Languages, C#, Formatting Style, Spaces
In the Around Operators check the Assignment operators.

The problem is going to be getting R# to only change that formatting and leave other things alone...

0

Please sign in to leave a comment.