Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2022-05-14 #7

Open
r7kamura opened this issue May 14, 2022 · 11 comments
Open

2022-05-14 #7

r7kamura opened this issue May 14, 2022 · 11 comments

Comments

@r7kamura
Copy link
Owner

No description provided.

@r7kamura
Copy link
Owner Author

rubocop-challengeをRailsアプリで動かそうとしてみたが、よく分からないエラーで動かず。

デバッグのために手元でrubocop_challengerを直接実行してみると、更に違うエラーが出て動かず… そもそも rubocop_challenge go を実行すると、そのRailsアプリに含まれているGemfileの内容で bundle install を始めてしまい、なぜそんなことが実行されるのかよく分からない。rubocopの実行に必要なのは、.rubocop.yml のrequireの項目で定義されているものだけのはずなので、bundle install とかしてはいけない。

@r7kamura
Copy link
Owner Author

bundle install の問題は、とりあえずrubocop gem groupのものだけインストールするように、BUNDLE_WITHOUT環境変数を与えるというworkaroundで上手く解決した。そしてrubocop-challengeで発生するエラーを手元で再現できるようになった。

@r7kamura
Copy link
Owner Author

.rubocop.ymlからローカルの ./lib/foo.rb を読み込むようになっていたせいでエラーが出て処理が止まり、そこで.rubocop_todo.ymlが空の状態に更新され、それを後続の処理がパースしようとしてよく分からないエラーが出て失敗する、という状況だったようだ。

@r7kamura
Copy link
Owner Author

rubocop_challengerに色々とIssueを出した。

しかし真面目にこういうものを運用したい気持ちがあるなら、適切な機能だけを持つものを自作した方が良いのかもと思いつつある。

@r7kamura
Copy link
Owner Author

リンク切れを見かけたのでPull Requestを出した。

@r7kamura
Copy link
Owner Author

r7kamura commented May 14, 2022

試しにrubocop_todo_correctorをつくってみたい。

複雑になるので、Pull Requestを出したりする部分はライブラリの外側でやってもらいたいところだが、commitを複数用意してPRを出すとなるとやはりライブラリから叩かないとダメだろうか

@r7kamura
Copy link
Owner Author

味玉をつくりたいので、味玉のレシピも https://github.com/r7kamura/cooking に欲しい。

@r7kamura
Copy link
Owner Author

@r7kamura
Copy link
Owner Author

とりあえずリポジトリをつくった。実装はまだ無い。

https://github.com/r7kamura/rubocop_todo_corrector

@r7kamura
Copy link
Owner Author

とりあえずリポジトリをつくった。実装はまだ無い。

https://github.com/r7kamura/rubocop_todo_corrector

そこそこ実装を進めた。bundle installしてrubocop --auto-gen-configを実行できるところまでは出来たが、もう少し機能性を改善したい。50%ぐらいできた感じ。

@r7kamura
Copy link
Owner Author

運動不足解消の入り口として、腹筋ローラーを配信中にやると良いのではないか

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant