-
I manage a lot of files under The problem is, the So, why are they mutually exclusive in the first place? I feel like it's a valid use case. Technically, I COULD check if none of the programs that use Alternative ways to solve my problem would be a proper reverse ignore (include/allowlist) support like #2852, but it seems like people are against that idea. Or some kind of "profiles" support like dotdrop has would be cool, but that's too different from what chezmoi is doing. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 7 replies
-
For directories, The purpose of the If you want to avoid creating irrelevant files in the first place then use
I would also ask: does it really matter if |
Beta Was this translation helpful? Give feedback.
-
Thank you for clarifying the purpose of the attribute. It seems that my use of the attribute is unintended/misuse.
To me, yes. If a file/directory is not used, it shouldn't exist. I still think the functionality to ignore empty destination directories should exist (or even be the default behavior). Something like an attribute that is functionally similar to |
Beta Was this translation helpful? Give feedback.
For directories,
remove_
declares that the directory should not exist.private_
declares that the directory should exist and its permissions should only be readable by the user. Since these declarations disagree on whether the directory should exist or not, they are mutually exclusive.The purpose of the
remove_
attribute is to make it easier to remove directory entries across multiple devices. Once the directory entry is removed from all of your devices you can remove theremove_
entry from your source state. You can also use a.chezmoiremove
file.If you want to avoid creating irrelevant files in the first place then use
.chezmoiignore
. For example, if you only want~/.config/git/config
…