PowerShell Team has announced FxCop rules for cmdlet authors.

List of rules

  • AcceptForceParameterWhenCallingShouldContinue
  • AllCmdletsShouldAcceptPipelineInput
  • CallShouldProcessOnlyIfDeclaringSupport
  • DefineCmdletInTheCorrectNamespace
  • DoNotAccessPipelineParametersOutsideProcessRecord
  • DoNotCallCertainHostMethods
  • DoNotUseConsoleApi
  • FollowCmdletClassNamingConvention
  • OverrideProcessRecordIfAcceptingPipelineInput
  • ParameterShouldHaveConsistentTypePerNoun
  • UseCredentialAttributeForPSCredentialParameter
  • UseOnlyApprovedCharactersInVerbsAndNouns
  • UseOnlyStandardVerbs
  • UsePascalCasingInVerbsAndNouns
  • UseRecommendedParameterTypes
  • UseSingularNouns
  • UseSingularParameterNames
  • UseSwitchParameterInsteadOfBoolean

Leave a Reply

(required)

(required)

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>