ruby-gc

ruby-gc is a skill for Claude Code from joshukraine/dotfiles. It costs 25 tokens per session (2,454 once invoked), scanned A, original, MIT.

A safety-focused cleanup tool for Ruby versions installed through asdf, a tool that manages multiple language versions. It finds versions that no project or system setting refers to.

In plain words
What is it for?
Use it to preview unused Ruby versions and, after explicit confirmation, remove them with the apply option. It keeps globally selected or otherwise pinned versions.
Why use it?
It reduces the risk of deleting a Ruby version still needed by an application, and reports what it found before any removal.

Skill for Claude Code

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

Good fit Use it to preview unused Ruby versions and, after explicit confirmation, remove them with the apply option. It keeps globally selected or otherwise pinned versions.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/joshukraine/dotfiles/ruby-gc
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 joshukraine/dotfiles --skill ruby-gc
Clone the repo
git clone --depth 1 https://github.com/joshukraine/dotfiles

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 ruby-gc

README.md
[![agentmods](https://agentmods.dev/badge/skills/joshukraine/dotfiles/ruby-gc/github.svg)](https://agentmods.dev/skills/joshukraine/dotfiles/ruby-gc)
Your own site
<a href="https://agentmods.dev/skills/joshukraine/dotfiles/ruby-gc"><img src="https://agentmods.dev/badge/skills/joshukraine/dotfiles/ruby-gc/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 ruby-gc

Your own site · 80×15
<a href="https://agentmods.dev/skills/joshukraine/dotfiles/ruby-gc"><img src="https://agentmods.dev/badge/skills/joshukraine/dotfiles/ruby-gc.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 25 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,454 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.00025 $0.02454
Opus 5.5 $0.00010 $0.00982
Sonnet 5.5 $0.00005 $0.00491
Haiku 4.5 $0.00003 $0.00245

Measured 1mo ago against content hash 162ebefca600, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

ruby-gc 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 1mo 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.

claude/.claude/skills/ruby-gc/SKILL.md · 153 lines

How it starts

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

Ruby GC

Garbage-collect asdf-installed Ruby versions that nothing on the system references.

Dry-run by default. Without --apply, this is a read-only report and you must not uninstall anything.

Arguments

  • $ARGUMENTS — pass --apply to enable the uninstall step. Absent that flag, stop after the report.
  • --apply enables deletion; it does not authorize it. You still show the full table and get an explicit yes first.

Safety rules

These are non-negotiable. The cost of a wrong delete is a broken app plus a slow rebuild; the cost of a wrong keep is a few hundred MB.

  1. Never delete the global version — the one in ~/.tool-versions.
  2. Never delete a version that has any pin on disk, wherever that pin lives.
  3. Never delete without showing the table and getting an explicit confirmation in the same session.
  4. If the scan errors, or returns implausibly few pins, STOP and report. A truncated scan is indistinguishable from "nothing uses this" — it produces a confident delete list that breaks real apps. This has happened; treat a thin result as a bug in the scan, not a licence to delete. "Implausibly few" is measured against the July 2026 baseline in "Calibration" below — check it every run, before classifying anything.
  5. Uninstall one version at a time, reporting each result before the next.

Your task

1. Inventory what's installed

asdf list ruby
du -sh ~/.asdf/installs/ruby/*

2. Read the global pin

cat ~/.tool-versions

This is a symlink into ~/dotfiles/asdf/.tool-versions (the real dotfiles). Note that ~/code/my_repos/dotfiles/ and ~/dotfiles.bak/ are stale clones carrying outdated pins — ignore them as authorities on the global version, though their pins still count under rule 2 until the user cleans them up.

3. Scan for pins — FULL DEPTH

find ~ -type f \( -name .tool-versions -o -name .ruby-version \) \
  -not -path '*/node_modules/*' -not -path '*/.git/*' \
  -not -path '*/Library/*' -not -path '*/.Trash/*' \
  -not -path '*/vendor/*' -not -path '*/.asdf/*' \
  -not -path '*/.local/share/nvim/*' -not -path '*/.local/share/zap/*' \
  -not -path '*/.local/share/neobean/*' \
  -exec grep -H . {} + 2>/dev/null

Read the full file on GitHub · 153 lines

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. 1mo ago First seen · 153 lines · 25 tokens per session scan A 162ebefca600

Subscribe to this mod's changes

ruby-gc is a skill published in the GitHub repository joshukraine/dotfiles (429 stars, last pushed 5d ago), licensed MIT. It adds 25 tokens to every session and 2,454 once invoked, about $0.0001 per session on Opus 5.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-08-30.

Related

Other skills, from other repositories

python-conventions

Python coding conventions, modern tooling, and project setup. Apply when writing or reviewing Python code, creating projects, writing scripts, or migrating from legacy tools. Covers uv, ruff, ty, type hints, code structure, async, testing, and project configuration.

DJRHails/dotfiles · 57 tokens

golang-style

Go conventions specific to this author. Use before writing or editing any Go (.go) file.

fredrikaverpil/dotfiles · 23 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

ruby-rails

Use this skill when building Ruby on Rails applications — MVC, ActiveRecord, service objects, API mode, background jobs, and testing. This skill enforces: thin controllers, service objects for business logic, ActiveRecord query best practices, Rails API mode conventions, and RSpec testing patterns. Requires Rails 7+…

j4flmao/agent-skills · 94 tokens

astropy

Core Python library for astronomy and astrophysics workflows that need Astropy APIs, including units/quantities, coordinates, FITS I/O, tables, time systems, WCS, and cosmology. Use when implementing or debugging astronomical data analysis code with Astropy.

magic3007/dotfiles · 56 tokens

gsl-status

Query and configure the gsl (Go Status Line) that renders a powerline-style status bar in Claude Code and Antigravity CLI.

sfc-gh-eraigosa/dotfiles · 31 tokens