ReSharper Web Help

Using file headers for copyright notices and other identifying messages is a common practice. ReSharper provides a handy way to insert a common file header into code files in your solution in batch mode.

To configure a file header and insert it into code files
  1. Choose ReSharper | Options | Languages | Common | File Header Text.
  2. In the File Header Text area, insert an arbitrary text that you want to insert into your code files.
  3. Optionally, to surround the file header with a region, enter the name of the region in the Embrace File Header into Region with Name field.
  4. Choose Tools | Code Cleanup in the ReSharper Options dialog box.
  5. Create a new profile as described in Creating Custom Profiles . In the Selected profile settings for the new profile, select Update file header.
  6. Click OK to save the new profile and close the ReSharper Options dialog box.
  7. Open the Code Cleanup dialog box from the text editor or Solution Explorer as described in Running Code Cleanup . Note that triggering Code Cleanup upon a selection prevents ReSharper from inserting the file header.
  8. When the Code Cleanup dialog box opens, select the newly created profile in the Available Profiles area.
  9. Click Run to perform Code Cleanup. ReSharper will update all affected files with the file header.

See Also

Procedures