Skip to content

Instantly share code, notes, and snippets.

@lucasrowe
Last active September 29, 2016 04:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lucasrowe/19f3f421c0c528e1356c29ead59f3aba to your computer and use it in GitHub Desktop.
Save lucasrowe/19f3f421c0c528e1356c29ead59f3aba to your computer and use it in GitHub Desktop.
StyleCop Settings Examples
<StyleCopSettings Version=”105">
<GlobalSettings>
<BooleanProperty Name=”ViolationsAsErrors”>True</BooleanProperty>
</GlobalSettings>
<Analyzers>
<Analyzer AnalyzerId=”StyleCop.CSharp.DocumentationRules”>
<Rules>
<Rule Name=”FileMustHaveHeader”>
<RuleSettings>
<BooleanProperty Name=”Enabled”>False</BooleanProperty>
</RuleSettings>
</Rule>
</Rules>
<AnalyzerSettings>
<BooleanProperty Name=”IgnorePrivates”>True</BooleanProperty>
<BooleanProperty Name=”IncludeFields”>False</BooleanProperty>
</AnalyzerSettings>
</Analyzer>
</Analyzers>
</StyleCopSettings>
<StyleCopSettings Version=”105">
<GlobalSettings>
<BooleanProperty Name=”ViolationsAsErrors”>True</BooleanProperty>
</GlobalSettings>
<Parsers>
<Parser ParserId=”StyleCop.CSharp.CsParser”>
<ParserSettings>
<CollectionProperty Name=”GeneratedFileFilters”>
<Value>[^a-z ]AnimationAssetPostProcessor.cs</Value>
<Value>[^a-z ]AnimationClipHelper.cs</Value>
</CollectionProperty>
</ParserSettings>
</Parser>
</Parsers>
<Analyzers>
<Analyzer AnalyzerId=”StyleCop.CSharp.DocumentationRules”>
<Rules>
<Rule Name=”FileMustHaveHeader”>
<RuleSettings>
<BooleanProperty Name=”Enabled”>False</BooleanProperty>
</RuleSettings>
</Rule>
</Rules>
<AnalyzerSettings>
<BooleanProperty Name=”IgnorePrivates”>True</BooleanProperty>
<BooleanProperty Name=”IncludeFields”>False</BooleanProperty>
</AnalyzerSettings>
</Analyzer>
</Analyzers>
</StyleCopSettings>
<Parsers>
<Parser ParserId=”StyleCop.CSharp.CsParser”>
<ParserSettings>
<CollectionProperty Name=”GeneratedFileFilters”>
<Value>[^a-z ]AnimationAssetPostProcessor.cs</Value>
<Value>[^a-z ]AnimationClipHelper.cs</Value>
</CollectionProperty>
</ParserSettings>
</Parser>
</Parsers>
<StyleCopSettings Version="105">
<GlobalSettings>
<CollectionProperty Name="RecognizedWords">
<Value>char</Value>
<Value>Enum</Value>
<Value>int</Value>
<Value>stackoverflow</Value>
<Value>var</Value>
<Value>webplayer</Value>
<Value>Anim</Value>
<Value>keyframe</Value>
<Value>keyframes</Value>
<Value>redbluegames</Value>
<Value>minifish</Value>
<Value>Raycast</Value>
<Value>verteces</Value>
<Value>Monobehavior</Value>
<Value>Monobehaviour</Value>
<Value>Monobehaviors</Value>
<Value>Monobehaviours</Value>
<Value>behaviour</Value>
<Value>behaviour's</Value>
<Value>Coroutine</Value>
<Value>Coroutines</Value>
<Value>Coroutine</Value>
<Value>unpause</Value>
<Value>unpauses</Value>
<Value>spritesheet</Value>
<Value>php</Value>
</CollectionProperty>
<BooleanProperty Name="ViolationsAsErrors">True</BooleanProperty>
</GlobalSettings>
<Analyzers>
<Analyzer AnalyzerId="StyleCop.CSharp.DocumentationRules">
<Rules>
<Rule Name="FileMustHaveHeader">
<RuleSettings>
<BooleanProperty Name="Enabled">False</BooleanProperty>
</RuleSettings>
</Rule>
<Rule Name="FileHeaderMustShowCopyright">
<RuleSettings>
<BooleanProperty Name="Enabled">False</BooleanProperty>
</RuleSettings>
</Rule>
<Rule Name="FileHeaderMustHaveCopyrightText">
<RuleSettings>
<BooleanProperty Name="Enabled">False</BooleanProperty>
</RuleSettings>
</Rule>
<Rule Name="FileHeaderMustContainFileName">
<RuleSettings>
<BooleanProperty Name="Enabled">False</BooleanProperty>
</RuleSettings>
</Rule>
<Rule Name="FileHeaderFileNameDocumentationMustMatchFileName">
<RuleSettings>
<BooleanProperty Name="Enabled">False</BooleanProperty>
</RuleSettings>
</Rule>
<Rule Name="FileHeaderMustHaveValidCompanyText">
<RuleSettings>
<BooleanProperty Name="Enabled">False</BooleanProperty>
</RuleSettings>
</Rule>
<Rule Name="FileHeaderFileNameDocumentationMustMatchTypeName">
<RuleSettings>
<BooleanProperty Name="Enabled">False</BooleanProperty>
</RuleSettings>
</Rule>
<Rule Name="ElementDocumentationMustBeSpelledCorrectly">
<RuleSettings>
<BooleanProperty Name="Enabled">False</BooleanProperty>
</RuleSettings>
</Rule>
</Rules>
<AnalyzerSettings>
<BooleanProperty Name="IgnorePrivates">True</BooleanProperty>
<BooleanProperty Name="IncludeFields">False</BooleanProperty>
</AnalyzerSettings>
</Analyzer>
<Analyzer AnalyzerId="StyleCop.CSharp.NamingRules">
<AnalyzerSettings>
<CollectionProperty Name="Hungarian">
<Value>ai</Value>
<Value>cs</Value>
<Value>fx</Value>
<Value>up</Value>
<Value>x</Value>
<Value>y</Value>
<Value>at</Value>
</CollectionProperty>
</AnalyzerSettings>
</Analyzer>
</Analyzers>
</StyleCopSettings>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment