Closed bonecountysheriff closed 10 months ago
A couple of options:
1) Store the private parts of the file in your password manager and use a password manager template function to retrieve them. I use this approach.
2) Encrypt the private parts of the file and use the decrypt
template function to decrypt them.
3) Include the parts as separate files in either .chezmoitemplates
or .chezmoidata
in your source directory and use .gitignore
to avoid storing them in your git repo. You'll then need to distribute and update the files manually.
What exactly are you trying to do?
There's a folder in the destination directory that I cannot include in the dotfiles because of security reasons (my dotfiles need to be publicly hosted). This directory is a collection of text config files and I need to include them in a chezmoi template file.
I need to know if this is possible using chezmoi templates.
\<source-dir>/config.txt.tmpl
When applied, this should lead to the following destination config file.
\<destination-dir>/config.txt
What have you tried so far?
I have gone through https://www.chezmoi.io/user-guide/include-files-from-elsewhere/, but I'm not sure it is what I am looking for since it mentions web hosted files but not local ones.
Where else have you checked for solutions?