doctor command checks your system for potential problems and reports the results. It helps diagnose configuration issues and verify that all required tools are properly installed.
Usage
Description
Thedoctor command performs a comprehensive health check of your chezmoi installation and environment. It verifies:
- Version information: chezmoi version, Go version, OS/arch
- Configuration: Config file location and validity
- Directories: Source, working tree, and destination directories
- VCS: Git repository status (clean, dirty, or error)
- Tools: Editor, shell, diff, merge, and git commands
- Encryption: age, GPG, and other encryption tools
- Secret managers: 1Password, Bitwarden, LastPass, etc.
- System capabilities: Symlinks, hard links
ok- Check passedinfo- Informational message (not a problem)warning- Potential issue (chezmoi will still work)error- Problem that needs to be fixedskipped- Check was skipped (e.g., no network for version check)failed- Check could not be completed
Flags
Do not use network connection. Skips the latest version check.
Examples
Run a full health check
Run without network access
Check exit code
error.
Terminal Output
Check Descriptions
Version Checks
version- Shows chezmoi version, commit, and build date
warningif version information is incomplete
- Compares installed version with latest GitHub release
warningif a newer version is availableskippedwith--no-network
- Shows Go version used to build chezmoi
- Shows operating system and architecture
- Includes OS release information if available
Executable Checks
executable- Shows path to chezmoi binary
- Shows detected upgrade method (e.g.,
brew-upgrade,snap-refresh) - Helps determine how to upgrade chezmoi
Configuration Checks
config-file- Validates config file exists and is readable
- Shows path and last modification time
infoif config file doesn’t exist (optional)errorif config file is invalid
Directory Checks
source-dir- Verifies source directory exists
- Shows git status if it’s a repository:
(clean)- No uncommitted changes(dirty)- Uncommitted changes present(error)- Git error
- Verifies working tree directory exists
- Verifies destination directory exists
Tool Checks
cd-command, edit-command, shell-commanderrorif not found and required- Shows path and version if available
infoif not set (optional tools)warningif set but not found
warningif not found- Shows version if found
Encryption Tool Checks
age-command, gpg-commandinfoif not found (optional)- Shows version if found
- Used by GPG for password entry
infoif not setwarningif set but not found
Secret Manager Checks
1password-command, bitwarden-command, etc.infoif not found (optional)- Shows version if found
errorif found but version is too old
System Capability Checks
symlink- Tests if symbolic links can be created
failedif symlinks not supported
- Tests if hard links can be created
- Shows current umask value