lang-ruby
Skill5 starsChanged 46 days agoMITView on GitHub
use this when writing, reviewing, or testing Ruby — *.rb, Gemfile. do not use for Rails-only architecture; stay on the language. do not use for Python.
In this repository49 other files it gives its agents.
- AGENTS.mdAGENTS.md
- maintainers/AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- buying-researcherSkill
- cursor-cloud-agents-whenSkill
- debug-anthropicSkill
- debug-pocockSkill
- debugSkill
- discover-the-ideaSkill
- docs-google-styleSkill
- golang-safetySkill
- golang-securitySkill
- golang-testingSkill
- grok-acpSkill
- host-config-pyinfraSkill
- lang-cppSkill
- lang-csharpSkill
- lang-cSkill
- lang-dartSkill
- lang-dockerSkill
- lang-goSkill
- lang-javaSkill
- lang-js-tsSkill
- lang-kotlinSkill
- lang-luaSkill
- lang-makefileSkill
- lang-phpSkill
- lang-powershellSkill
- lang-protobufSkill
- lang-pythonSkill
- lang-rustSkill
- lang-shellSkill
- lang-sqlSkill
- lang-swiftSkill
- lang-terraformSkill
- language-routerSkill
- lang-web-markupSkill
- modern-pythonSkill
- pr-reviewSkill
- sdlc-artifactsSkill
- sdlc-onboardingSkill
- security-hardeningSkill
- shell-safetySkill
- tddSkill
- tracker-sdlcSkill
- ui-craftSkill
- ux-designSkill
- verify-before-doneSkill
- yagniSkill
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 2 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 23
Use whatever the repo already runs.
- Very specific: line 37
No empty rescue. No rescue nil.
- Distinctive: line 43
No mutable class variables as global state.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Ruby
Language, not a Rails pack. No scripts/.
Process skills that may load with this one: language-router Load-with list.
Iron law
Be explicit. Don't monkey-patch in app code. Parameters, not string SQL.
Tooling / verify
bundle exec rspec # or
bundle exec rake testUse whatever the repo already runs. Do not add a second test framework.
Idioms a linter misses
- Keyword args for 3+ parameters.
- Frozen string literals if the file/project already uses them.
- Raise specific errors. Do not rescue
StandardErrorto return nil. - Enumerable methods over index loops when they are clearer.
- Predicate methods end in
?. Bang methods mutate or raise as the existing API already does — do not invent a new convention.
Errors
- Rescue the type you can handle. Re-raise the rest.
- No empty rescue. No
rescue nil.
Concurrency
- MRI threads are not a scaling plan. If you add threads, document what is shared and what is not.
- No mutable class variables as global state.
Testing
- minitest or RSpec as the repo chose. One behavior per example.
- Doubles at I/O boundaries. Do not stub the type under test into meaninglessness.
PR review
- New gem: why not stdlib or an existing gem?
- New monkey-patch of a core class: reject in app code.
- SQL and shell interpolation.
Security
- SQL via binds. No
#{user}in queries. - No
eval, nosendof untrusted names, noconstantizeof user strings. system/ backticks: argument arrays, not interpolated strings.- Mass-assignment: permit lists as the framework already does.
Always
- Specific raises. Binds. Tests for the new branch.
Ask first
- Adding a gem when stdlib will do.
- Introducing Rails helpers in a non-Rails gem.
Never
- Rescue-and-ignore.
- Monkey-patching core classes in application code.
eval/ untrustedsend.- Interpolated
system.
Red flags
- "I'll rescue StandardError and move on"
- "It's Ruby, duck typing means no checks"
- "send is fine, the string is almost static"
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

