update command pulls the latest changes from your source repository and optionally applies them to your system.
Usage
Description
Theupdate command combines pulling changes from your version control system with applying those changes to your destination directory.
Default behavior:
- If
update.commandis set in the config, chezmoi runs that command withupdate.argsin the working tree - Otherwise, chezmoi runs
git pull --autostash --rebase(with--recurse-submodulesif enabled) - Uses chezmoi’s builtin git if
useBuiltinGitistrueor ifgit.commandcannot be found in$PATH
Flags
Apply changes after pulling. Can be disabled with
--apply=false.Update submodules recursively. Can be disabled with
--recurse-submodules=false. Can be configured via update.recurseSubmodules in the config file.Exclude entry types (comma-separated:
dirs, files, remove, scripts, symlinks, always, encrypted, externals, templates).Include only specified entry types (comma-separated:
dirs, files, remove, scripts, symlinks, always, encrypted, externals, templates).Recreate the config file from the template in the source directory.
Apply changes to all parent directories.
Recurse into subdirectories when applying.