Table of Contents
Overview
yq is a lightweight and portable command-line YAML, JSON, and XML processor. It’s written in Go and uses similar syntax to jq.
Key Features
- YAML/JSON/XML processing
- Multi-document support
- Format conversion
- In-place editing
- Expression evaluation
- Array operations
- Document merging
- Path-based updates
Basic Usage
Simple Operations
Common Options
YAML Operations
Basic Queries
Modifications
Value Operations
Structure Modifications
Multi-Document Processing
Document Operations
Document Manipulation
YAML/JSON Conversion
XML Operations
Advanced Features
Expression Evaluation
Path Operations
Best Practices
Error Handling
Example Scripts
Kubernetes Config Management
Configuration Generator
YAML Validation
Multi-Environment Config
Document Merger