Skip to content

Prompt before overwriting on first run #2861

Answered by twpayne
liancea asked this question in Q&A
Discussion options

You must be logged in to vote

Overwriting never-before-written files is exactly what you want to do when you setup your dotfiles on a new machine. This is by far the most common use case, and so needs to be the default.

The chezmoi diff command tells you exactly what changes chezmoi apply will make, and the quick start guide emphasizes that you should run chezmoi diff to check the changes before you run chezmoi apply.

Also, the quick start guide recommends using chezmoi add to add a file to be managed by chezmoi, then chezmoi edit, then chezmoi apply. If you follow this process, then you will get a warning if you modify the original dotfile between the chezmoi add and the chezmoi apply.

It would be possible to add a, …

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@liancea
Comment options

Answer selected by liancea
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants