Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add /apply option to write /fixall changes back to disk #2017

Merged
merged 3 commits into from
Jan 12, 2016

Conversation

sharwell
Copy link
Member

This update to StyleCopTester allows it to be used to automate the correction of specific style violations in a solution.

Currently only one type of diagnostic can be fixed at a time, but it would be easy to create a script that invokes the tool multiple times to cover a set of diagnostics.

@codecov-io
Copy link

Current coverage is 93.30%

Merging #2017 into master will increase coverage by +0.01% as of f0ef849

@@            master   #2017   diff @@
======================================
  Files          561     561       
  Stmts        35580   35580       
  Branches      2283    2283       
  Methods                          
======================================
+ Hit          33195   33198     +3
  Partial        751     751       
+ Missed        1634    1631     -3

Review entire Coverage Diff as of f0ef849

Powered by Codecov. Updated on successful CI builds.

@sharwell sharwell modified the milestones: 1.1.0 Beta 1, 1.0.0 Jan 8, 2016
if (applyChanges)
{
var applyOperations = operations.OfType<ApplyChangesOperation>().ToList();
if (applyOperations.Count > 1)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sharwell Do you know a case where this can happen?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I do not. Presumably if this message ever appears someone will report it.

@pdelvo
Copy link
Member

pdelvo commented Jan 12, 2016

👍

sharwell added a commit that referenced this pull request Jan 12, 2016
Add /apply option to write /fixall changes back to disk
@sharwell sharwell merged commit e17ea25 into DotNetAnalyzers:master Jan 12, 2016
@sharwell sharwell deleted the apply-fixes branch January 12, 2016 12:37
@oatkins
Copy link
Contributor

oatkins commented Jan 12, 2016

Excellent! This will be really helpful. 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants