RubocopPr
CLI Issues and PR creator for Rubocop Cops. 1 linter == 1 issue == 1 PR.
Simplify the inception or version bump of Rubocop on the project.
With RubocopPr you can apply Rubocop clean and in a few minutes, see the example.
Requirements
- Ruby 2.1+
- Hub 2.12.3 (tested with this version only, but should work with older versions)
- Github
Installation
Add this line to your application's Gemfile:
gem 'rubocop_pr', require: false
And then execute:
$ bundle
Or install it yourself as:
$ gem install rubocop_pr
Usage
Usage: rubocop_pr [options]
-u, --hub-version [version] Set manually minimum required version of 'hub' utility for github (default: 2.12.3)
-b, --branch [branch] internal branch with '.rubocop_todo.yml' (default: 'rubocop_todo_branch')
-m, --master [branch] branch which will be the base for all PR's (default: 'master')
-r, --post-checkout [command] Running after each git checkout (default: "")
-l, --limit [limit] Limit the PS's for one run (default: 10)
-g, --repository [name] Set repository host (default: github)
-o, --origin [origin] origin option for 'git push' (default: 'origin')
-c, --continue Continue previous session (default: false)
-v, --version Display version
-h, --help Display help
Notes
brachoption is useful, if you want to prepare the.rubocop-todo.ymlmanually and feed it torubocop_pr.post-checkouthandy for old Ruby versions, when shell may "forget" Ruby version.
Contributing
Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/rubocop_pr. 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 RubocopPr project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the code of conduct.