rubocop-todo-fix

rubocop-todo-fix is a skill for Claude Code from SonicGarden/sgcop. It costs 80 tokens per session (9,198 once invoked), scanned A, original, MIT.

A Ruby and Rails code-cleanup workflow for resolving violations listed in RuboCop's todo file. RuboCop is a tool that checks Ruby code against style and quality rules; the todo file records existing violations that were temporarily allowed.

In plain words
What is it for?
Use it to process safe and unsafe RuboCop fixes, make necessary manual corrections, remove resolved entries from the todo file, and rerun checks until the selected violations are gone.
Why use it?
It turns a large cleanup into smaller reviewable batches and separates low-risk automatic changes from changes that may alter behaviour. It leaves commits, pushes, and pull requests to you.

Skill for Claude Code

Written for Claude Code: disable-model-invocation in frontmatter.

Good fit Use it to process safe and unsafe RuboCop fixes, make necessary manual corrections, remove resolved entries from the todo file, and rerun checks until the selected violations are gone.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/sonicgarden/sgcop/rubocop-todo-fix
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add SonicGarden/sgcop --skill rubocop-todo-fix
Clone the repo
git clone --depth 1 https://github.com/SonicGarden/sgcop

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for rubocop-todo-fix

README.md
[![agentmods](https://agentmods.dev/badge/skills/sonicgarden/sgcop/rubocop-todo-fix/github.svg)](https://agentmods.dev/skills/sonicgarden/sgcop/rubocop-todo-fix)
Your own site
<a href="https://agentmods.dev/skills/sonicgarden/sgcop/rubocop-todo-fix"><img src="https://agentmods.dev/badge/skills/sonicgarden/sgcop/rubocop-todo-fix/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for rubocop-todo-fix

Your own site · 80×15
<a href="https://agentmods.dev/skills/sonicgarden/sgcop/rubocop-todo-fix"><img src="https://agentmods.dev/badge/skills/sonicgarden/sgcop/rubocop-todo-fix.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 80 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 9,198 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00080 $0.09198
Opus 5 $0.00040 $0.04599
Sonnet 5 $0.00016 $0.01840
Haiku 4.5 $0.00008 $0.00920

Measured 5d ago against content hash 58144f27efb0, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade A, and why

rubocop-todo-fix scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/rubocop-todo-fix/SKILL.md · 333 lines

How it starts

The opening of the file, as written. The whole thing — 333 lines — stays where its author put it; the contents beside it link to each section on GitHub.

rubocop-todo-fix

rubocop --auto-gen-config で生成された .rubocop_todo.yml には、既存コードの違反が「いったん許容」 として列挙されている。これを潰していくための運用支援スキル。safe autocorrect(-a)だけで完結する Cop はまとめてバッチ処理し、unsafe autocorrect や手動修正が必要な Cop も、挙動変更のリスクに応じた (safe バッチより狭い)単位でバッチにまとめて潰す。 sgcop-setup.rubocop_todo.yml生成するところで終わるのに対し、 本スキルはその続き——生成済みの todo を実際に消化する工程——を担う。

導入先の Rails/Ruby プロジェクトで実行する(sgcop gem 本体の開発スキルではない)。

このスキルがやること / やらないこと

  • やる:
    1. .rubocop_todo.yml から 潰す対象を選ぶ。Tier(safe autocorrect / unsafe autocorrect / 手動修正)ごとに、そのリスクに見合ったしきい値・基準で複数 Cop をバッチにまとめる。
    2. 対象 Cop のエントリを todo から削除して 違反を再び検出される状態に戻す
    3. 修正する: Tier 順(rubocop -arubocop -A〈unsafe・要テスト〉→ 手動修正)でバッチを 処理する。同じ Tier のバッチはまとめて一度に適用・確認する。
    4. アプリ仕様上やむを得ない違反だけ、理由コメント付きで最小範囲の Exclude / 無効化に倒す。
    5. 再 rubocop で 違反ゼロを確認(挙動を変えたら関連テストだけ実行)し、必要なら .rubocop_todo.yml を作り直して 停止する
  • やらない:
    • .rubocop_todo.yml の生成そのものはしない(sgcop-setup の担当。本スキルは「生成済みを潰す」)。
    • コミット / push / PR 作成はしない。 1 サイクル潰したら停止し、差分確認とコミットはユーザーに委ねる。
    • Tier をまたいでバッチにしない。 safe / unsafe / 手動修正はリスクの質が異なるので、 1 回のバッチは同じ Tier の Cop だけで構成する。

なぜこの形か: 既存違反を一度に全部直すと差分が巨大化してレビュー不能になる。「潰す → ユーザーが差分を確認してコミット → 次へ」というレビュー単位の運用にすると、変更の責任範囲が 把握しやすく、挙動が変わっても切り分けやすい。一方で 1 Cop ずつ処理すると、サイクル数 (起動〜レビュー〜コミットの往復)だけが無駄に増えてしまう。そこで Tier ごとに「レビューが 破綻しない範囲」を見極めてバッチ化する:safe autocorrect は挙動を変えないので件数ベースで 最も広く(目安100件)まとめられる。unsafe autocorrect は挙動が変わりうるので、それより 狭い件数(目安30件)に抑える。手動修正はさらに読み解きコストが件数に比例しないため、 件数ではなく「性質が近い少数の Cop(目安2〜3個)」という基準でまとめる。

引数

  • --auto: 起動時にこの引数が渡されたら、1 サイクルをユーザー確認なしで回しきるモードに入る。 スキップするのは「進めてよいか」の確認ゲートだけで、それ以外の原則は一切変わらない:
    • **1 サイクル = 選んだバッチ(Tier をまたがない)**の原則、コミット・push・PR をしない原則、 サイクル完了で停止する原則は --auto でも不変。複数サイクルの自動連続実行はしない。
    • 人間の判断が要る曖昧な分岐は --auto でも勝手に決めない(手順 5 参照)。触らず残して報告する。
    • 手順 6 の関連テスト検証は --auto でも省かない。 unsafe autocorrect を無確認で当てる分、 関連テストが挙動変更を検知する唯一の安全網になるため、むしろ飛ばしてはいけない。
    • WHY: 確認ゲートは「差分が想定外に大きくならないか」「挙動変更を許容するか」を人に確かめる ためのもの。--auto は呼び出し側がその判断を事前に委譲した状態、と位置づける。委譲できるのは 「自動で潰してよい」判断までで、曖昧な Exclude 判断や壊れたテストの承認までは委譲されない。
  • 引数が無ければ(従来どおり)各確認ゲートでユーザーに確認する。

Read the full file on GitHub · 333 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 333 lines · 80 tokens per session scan A 58144f27efb0

Subscribe to this mod's changes

rubocop-todo-fix is a skill published in the GitHub repository SonicGarden/sgcop (22 stars, last pushed today), licensed MIT. It adds 80 tokens to every session and 9,198 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-04.

Related

Other skills, from other repositories

rubyllm

Build and maintain Ruby or Rails applications with the RubyLLM AI framework. Use for chats, agents, tools, structured output, media generation, transcription, OCR, moderation, embeddings, reranking, Rails integration, and RubyLLM upgrades; not for contributing to the framework itself.

crmne/ruby_llm · 61 tokens

new

Create a new project to start development quickly.

clacky-ai/openclacky · 10 tokens

rspec-conventions

Rootstrap RSpec conventions. Use when writing, reviewing, or editing RSpec test files (spec//spec.rb, spec/railshelper.rb, spec/spechelper.rb, spec/support//.rb) or factories. Covers describe/context structure, let/subject, matchers, factories, mocking/stubbing, shared examples, and spec types (model, request…

rootstrap/rails_api_base · 82 tokens

ruby-patterns

Ruby/Rails: blocks, metaprogramming, ActiveRecord, Sidekiq, RSpec, Sorbet, Hanami. Triggers: Ruby, Rails, ActiveRecord, Sidekiq, RSpec, Gemfile, bundler, Hanami, Sorbet.

softspark/ai-toolkit · 60 tokens

ruby-rules

Ruby coding rules: style, patterns, security, testing. Triggers: .rb, Gemfile, .gemspec, Rails, ActiveRecord, Sidekiq, RSpec, Sorbet, rubocop.

softspark/ai-toolkit · 48 tokens

ruby-expert

Expert-level Ruby development with Rails, modern features, testing, and best practices. Use when the user mentions Ruby on Rails, RSpec, gem, Sinatra, or metaprogramming, or when the task involves Ruby 3+ Features, Object-Oriented, Functional Features, or Pattern Matching.

personamanagmentlayer/pcl · 64 tokens