rubocop-packs

0.0.45last stable release 4 months ago
Complexity Score
Low
Open Issues
0
Dependent Projects
3
Weekly Downloadsglobal
1,719

License

  • MIT
    • Yesattribution
    • Permissivelinking
    • Permissivedistribution
    • Permissivemodification
    • Nopatent grant
    • Yesprivate use
    • Permissivesublicensing
    • Notrademark grant

Downloads

Readme

rubocop-packs

A collection of Rubocop rules for modularizing ruby applications that conform to the packs standard.

Installation

Just install the rubocop-packs gem

gem install rubocop-packs

or, if you use Bundler, add this line your application’s Gemfile:

gem 'rubocop-packs', require: false

Usage

You need to tell RuboCop to load the Packs extension. There are three ways to do this:

RuboCop configuration file

Put this into your .rubocop.yml:

require:
  - rubocop-packs

Now you can run rubocop and it will automatically load the RuboCop Packs cops together with the standard cops.

The Cops

All cops are located under lib/rubocop/cop/packs, and contain examples/documentation.

In your .rubocop.yml, you may treat the Packs cops just like any other cop. For example:

Packs/RootNamespaceIsPackName:
  Exclude:
    - lib/example.rb

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/rubyatscale/rubocop-packs. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the Code Of Conduct.

To contribute a new cop, please use the supplied generator like this:

bundle exec rake new_cop[Packs/NewCopName]

which will create a skeleton cop, a skeleton spec, an entry in the default config file and will require the new cop so that it is properly exported from the gem.

Don’t forget to update the documentation with:

VERIFYING_DOCUMENTATION=1 bundle exec rake generate_cops_documentation

License

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

Dependencies

No runtime dependency information found for this package.

CVE IssuesActive
0
Scorecards Score
No Data
Test Coverage
No Data
Follows Semver
Yes
Github Stars
14
Dependenciestotal
13
DependenciesOutdated
1
DependenciesDeprecated
0
Threat Modelling
No
Repo Audits
No

Learn how to distribute rubocop-packs in your own private RubyGems registry

gem install rubocop-packs
Processing...
Done

38 Releases

RubyGems on Cloudsmith

Getting started with RubyGems on Cloudsmith is fast and easy.