Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Get resharper issues for new/modified code between two changesets

I'm wondering is there any way to find out resharper issues only for new and modified lines of code between two revisions?

For example, I start with baseline version with number 50 for given repository. Over the period of 1 month, say around 20 files are changed, 5 new are added. The latest revision number is say 100. I can easily check for 5 new files if any comment is pending to get fixed.

But for 20 modified files, how can one find list of comments in one shot. As of now, I compare version 100 and 50 of file abc.cs and find out new/modified code in SVN DIFF and go to IDE to that line to check if there is any issue raised for it by resharper. Which is very time consuming. Is there any efficient way to fix issues for incremental code? For example - get all review comments with line numbers for incremental code for those 20 files.

like image 309
Neeraj Bopalkar Avatar asked Dec 04 '25 01:12

Neeraj Bopalkar


1 Answers

I did not try it, but may be something like this may work for you:

  • get the code of the baseline revision from the repository;
  • run R# code inspection on it
  • export the inspection results to an XML file baseline.xml: exporting code issues
  • repeat the above steps on the latest revision code
  • compare the XML results of the inspection (baseline.xml and latest.xml) by some diff utility.

Also I found a script which I may try to use myself: http://jbazuzicode.blogspot.com/2014/05/automating-resharpers-inspect-code.html

If you try this script, please tell your feedback on it.

like image 139
Andrej Adamenko Avatar answered Dec 06 '25 16:12

Andrej Adamenko



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!