cli-config

Community

Design robust CLI configs with Cobra & Viper.

Authoryurifrl
Version1.0.0
Installs0

System Documentation

## What problem does it solve? This Skill helps developers configure CLI applications using Cobra and Viper, simplifying how settings flow from defaults, config files, environment variables, and flags.

## Core Features & Use Cases

  • Bind Cobra flags to Viper values for centralized config management.
  • Support multiple formats (yaml/json/toml) for configuration files.
  • Provide helper commands (init/show/validate) to manage and validate config.

### Quick Start

  1. Create a new Go module and import github.com/spf13/cobra and github.com/spf13/viper.
  2. Create a sample config.yaml with keys like server.port and server.host, and bind command flags to Viper keys.
  3. Run a simple workflow: init config, show config, and validate configuration.

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: cli-config
Download link: https://github.com/yurifrl/cly/archive/main.zip#cli-config

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.