/momocop

Convention focused opinionated custom cops for RuboCop.

Primary LanguageRubyMIT LicenseMIT

English | 日本語

momocop

Spec Gem Version

Momocop is highly opinionated custom cops for RuboCop.

Installation

Add momocop to your Gemfile.

# Gemfile
gem 'momocop', require: false

Usage

Edit .rubocop.yml to require momocop and enable the cops you want.

All cops are disabled by default.

# .rubocop.yaml
require:
  - momocop

Momocop/FactoryBotClassExistence:
  Enabled: true
Momocop/FactoryBotConsistentFileName:
  Enabled: true
Momocop/FactoryBotInlineAssociation:
  Enabled: true
Momocop/FactoryBotMissingAssociations:
  Enabled: true
Momocop/FactoryBotMissingClassOption:
  Enabled: true
Momocop/FactoryBotMissingProperties:
  Enabled: true
Momocop/FactoryBotPropertyOrder:
  Enabled: true
Momocop/FactoryBotSingleDefinePerFile:
  Enabled: true
Momocop/FactoryBotSingleFactoryPerDefine:
  Enabled: true
Momocop/FactoryBotSingularFactoryName:
  Enabled: true
Momocop/Layout/LeadingCommentSpace:
  Enabled: true

Cops

Cop Rails FactoryBot
Momocop/FactoryBotClassExistence
Momocop/FactoryBotConsistentFileName
Momocop/FactoryBotInlineAssociation
Momocop/FactoryBotMissingAssociations
Momocop/FactoryBotMissingClassOption
Momocop/FactoryBotMissingProperties
Momocop/FactoryBotPropertyOrder
Momocop/FactoryBotSingleDefinePerFile
Momocop/FactoryBotSingleFactoryPerDefine
Momocop/FactoryBotSingularFactoryName
Momocop/Layout/LeadingCommentSpace

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/supermomonga/momocop. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the code of conduct.

License

The gem is available as open source under the terms of the MIT License.

Code of Conduct

Everyone interacting in the Momocop project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the code of conduct.