ruby-yard-documenter

Add YARD documentation to Ruby classes and methods using Solargraph LSP.

Updated Dec 8, 2022
One-click install
npx skills add https://github.com/lekemula/dotfiles --skill ruby-yard-documenter
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ruby-yard-documenter
Source: https://github.com/lekemula/dotfiles/tree/main/claude/skills/ruby-yard-documenter
Command: npx skills add https://github.com/lekemula/dotfiles --skill ruby-yard-documenter

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill automates the process of adding comprehensive YARD documentation to Ruby code, improving code clarity, maintainability, and discoverability.

Core Features & Use Cases

  • Automated Documentation Generation: Identifies and adds YARD tags for classes, modules, and methods.
  • Intelligent Tagging: Uses Solargraph LSP to infer return types and exclude private/trivial methods.
  • Style Consistency: Adheres to project-specific YARD conventions for tone and tag usage.
  • Use Case: A developer needs to document a complex Ruby gem before releasing it. This Skill can automatically generate the initial YARD documentation, saving significant time and ensuring a consistent style.

Quick Start

Add YARD documentation to the file at $ARGUMENTS.

Frequently Asked Questions about ruby-yard-documenter

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automatically generate YARD documentation for Ruby methods?

To generate YARD documentation for Ruby, this Skill identifies undocumented classes and methods, then applies appropriate YARD tags. It uses Solargraph LSP for type inference to ensure tags accurately reflect return types and parameters.

Can I use Solargraph LSP to infer return types for YARD tags?

Yes, you can use Solargraph LSP to infer return types for YARD tags. The Skill leverages Solargraph to analyze Ruby code, automatically determining type information and applying the correct YARD tags to your documentation.

How do I exclude private or trivial Ruby methods from automated documentation generation?

You can exclude private or trivial Ruby methods from automated documentation generation through the Skill's intelligent tagging mechanism. It identifies undocumented elements while specifically excluding private or trivial methods, ensuring only relevant code receives YARD tags.

How do I ensure my Ruby YARD documentation follows project-specific conventions?

To ensure YARD documentation follows project-specific conventions, the Skill adheres to your project's defined style rules for tone and tag usage. It applies structured YARD tags consistently across classes and methods to enhance clarity and maintainability.

What is the best way to add YARD tags to a complex Ruby gem before release?

The best way to add YARD tags to a complex Ruby gem is using automated documentation generation. The Skill scans your files to identify undocumented elements, applies appropriate YARD tags using Solargraph for type inference, and saves significant time before release.