chezmoi

Synchronize dotfiles from repository sources to home directories with chezmoi.

8|1|Updated Jul 16, 2013
One-click install
npx skills add https://github.com/844196/dotfiles --skill chezmoi-844196
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: chezmoi
Source: https://github.com/844196/dotfiles/tree/main/.claude/skills/chezmoi
Command: npx skills add https://github.com/844196/dotfiles --skill chezmoi-844196

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

chezmoi provides a safe, source-driven workflow to manage dotfiles across machines by treating the repository as the single source of truth and applying changes to the home directory in a predictable, auditable manner.

Core Features & Use Cases

  • Source-driven management: treat the repository as the definitive origin of all configuration and apply changes to the target home directory with chezmoi apply.
  • Prefix conventions and templates: understand dot_ / exact_ / private_ / executable_ / symlink_ / empty_ / remove_ prefixes, Go templates ('.tmpl'), and how they map to target paths.
  • Lifecycle scripts and external resources: leverage .chezmoiscripts/ for pre/post actions and .chezmoiexternal.yaml for fetched resources, enabling reproducible setups and migrations.
  • Safe deletion and exactness: use exact_ directories to explicitly own a configuration subtree and manage removals via targeted files.
  • Cross-host consistency: use with and without .chezmoiscripts to apply same configuration across multiple machines.

Quick Start

Edit your dotfiles in the repository and run chezmoi apply to sync them to your home directory.

Frequently Asked Questions about chezmoi

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

FAQPage Schema
How do I manage dotfiles across multiple machines safely?

Dotfile management across multiple machines requires a source-driven workflow that treats the repository as the single source of truth and applies changes to the home directory predictably, ensuring safe, auditable synchronization using non-destructive apply semantics.

What is the best way to synchronize configuration files to my home directory?

Synchronizing configuration files to your home directory is best handled by editing files in the repository and running an apply command to sync them, using non-destructive semantics to ensure safety and traceability during the configuration lifecycle.

How do dotfile prefix conventions map to target paths?

Dotfile prefix conventions map to target paths by transforming repository attributes into specific file properties, where prefixes like dot_, exact_, private_, executable_, symlink_, empty_, and remove_ dictate file naming, protection, execution, or deletion in the target directory.

Can I use lifecycle scripts for reproducible initial setup and migrations?

Lifecycle scripts under .chezmoiscripts support reproducible initial setups and migrations by executing pre and post actions, enabling automated, predictable environment configuration alongside external resources fetched via .chezmoiexternal.yaml.

Does config management with Go templates work for cross-host consistency?

Config management with Go templates (.tmpl) works for cross-host consistency by allowing dynamic configuration generation, where using lifecycle scripts lets you apply the same templated configurations across multiple machines while maintaining host-specific variations.

When should I use exact directories to manage configuration subtrees?

Exact directories should be used to manage configuration subtrees when you need to explicitly own a configuration path and ensure safe deletion, allowing targeted file removal and preventing untracked files from persisting in managed directories.