1
0
mirror of https://github.com/deadc0de6/dotdrop.git synced 2026-02-04 14:31:46 +00:00

dynamic dotfile example in doc

This commit is contained in:
deadc0de6
2021-10-12 21:09:40 +02:00
parent 479c7796bc
commit 2704df494a

View File

@@ -601,6 +601,27 @@ profiles:
- f_somefile
```
Or when you need to select the dotfile to deploy depending on
the profile used (`ssh_config.perso` for the profile `perso` and
`ssh_config.work` for the `work` profile):
```yaml
dotfiles:
f_ssh_config:
src: "{{@@ ssh_config_file @@}}"
dst: ~/.ssh/config
profiles:
perso:
dotfiles:
- f_ssh_config
variables:
- ssh_config_file: "ssh_config.perso"
work:
dotfiles:
- f_ssh_config
variables:
- ssh_config_file: "ssh_config.work"
```
## Dynamic dotfile link value
Dotfile `link` values can be dynamically constructed using