0.0
No release in over a year
Rules for linting Rails code at Panorama Education. Use the latest git commit of this gem instead of the version pushed to RubyGems.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

= 5.4.1
 Project Readme

panolint-rails

Build Status

A small gem containing rules for linting Ruby on Rails code at Panorama Education.

This gem inherits RuboCop configuration from panolint-ruby.

Installation

Add these lines to your application's Gemfile:

gem "panolint-ruby", git: "https://github.com/panorama-ed/panolint-ruby.git", branch: "main"
gem "panolint-rails", git: "https://github.com/panorama-ed/panolint-rails.git", branch: "main"

It is necessary to have panolint-ruby in your application's Gemfile. This is necessary despite panolint-rails's Rubocop configuration inheriting from panolint-ruby because we want to point to the up-to-date GitHub repository rather than the initial version on RubyGems. panolint-rails cannot simply have panolint-ruby as a dependency in its gemspec because the gemspec can only point to RubyGems but not GitHub repositories as we would desire it to.

And then execute:

$ bundle

Do not install this gem from RubyGems, as updates are only pushed to this repo. We have only pushed an initial version to RubyGems to avoid supply chain attacks from malicious squatters.

Usage

Brakeman

You can use panolint-rails's brakeman configuration in your project by pointing the brakeman run at the configuration file in this repo:

$ bundle exec brakeman -c "$(bundle show brakeman)/brakeman.yml"

RuboCop

You can use panolint-rails's RuboCop configuration in your project with the following addition to the top of your project's .rubocop.yml:

inherit_gem:
  panolint-rails: panolint-rails-rubocop.yml

This gem uses a gem-specific named file instead of the traditional .rubocop.yml due to a previous issue with RuboCop extensions in VS Code reading the wrong repository's .rubocop.yml file.

Contributing

While this gem is intended for internal use by Panorama Education engineers, bug reports and pull requests are welcome on GitHub at https://github.com/panorama-ed/panolint-rails. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the Contributor Covenant 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 panolint-rails's project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the code of conduct.