yaml-reader

Parse and query YAML files with yq for values and nested structures.

5|Updated Jun 14, 2020
One-click install
npx skills add https://github.com/PrayagS/dotfiles --skill yaml-reader
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: yaml-reader
Source: https://github.com/PrayagS/dotfiles/tree/main/config/claude/skills/yaml-reader
Command: npx skills add https://github.com/PrayagS/dotfiles --skill yaml-reader

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

YAML files often act as configuration sources across tools like Kubernetes manifests, Docker Compose files, and Helm charts. This skill makes it easier to read, validate, and extract data from YAML documents using the yq command-line tool, reducing manual parsing work and human errors.

Core Features & Use Cases

  • Key discovery: list top-level and nested keys to understand the document structure.
  • Value retrieval: extract single or multiple values with concise queries.
  • Validation and multi-document support: verify YAML syntax and process multiple documents in a single file.
  • Common use cases: inspecting Kubernetes manifests, Docker Compose configurations, and Helm values to quickly locate resources, versions, and settings.

Quick Start

Query a YAML file with yq to retrieve a value by its key path.

Frequently Asked Questions about yaml-reader

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

FAQPage Schema
How do I extract a specific value from a Kubernetes manifest?

To extract values from a Kubernetes manifest, query the YAML file with yq by specifying the key path to retrieve single or multiple nested values. This approach reduces manual parsing errors when inspecting configurations.

Can I process multiple documents in a single YAML file?

Yes, you can process multi-document YAML files. This skill handles multiple documents within a single file, allowing you to validate syntax and extract data across all included documents using YAML streams.

How do I list all top-level keys in a Docker Compose configuration?

To list all top-level keys in a Docker Compose configuration, use the key discovery feature with yq to map the document structure. This allows you to understand the hierarchy and navigate nested settings efficiently.

What is the best way to validate Helm chart syntax?

The best way to validate Helm chart syntax is by using yq to parse the YAML files. This verifies the structure and syntax, ensuring your chart configurations are correctly formatted before deployment.

Does this approach work for generic configuration files beyond Kubernetes?

Yes, this approach works for generic configuration files beyond Kubernetes. You can parse and query any YAML file using yq to extract values, discover keys, and validate syntax across various tools and platforms.