Add template for chezmoi.toml

bladee.bsky.social 5f037405 a83357d9

verified
+18
.chezmoi.toml.tmpl
···
+
[data]
+
{{ $machineTypeChoices := list "personal" "work" -}}
+
{{ $machineType := promptChoiceOnce . "machineType" "Machine type" $machineTypeChoices -}}
+
machineType = {{ $machineType | quote }}
+
+
{{- if eq .chezmoi.os "linux" }}
+
opDir = "/opt/1Password"
+
{{ else if eq .chezmoi.os "darwin" }}
+
opDir = "/Applications/1Password.app/Contents/MacOS"
+
{{- end }}
+
+
[data.git]
+
{{ $gitName := promptStringOnce . "git.name" "Git name" -}}
+
name = {{ $gitName | quote }}
+
{{ $gitEmail := promptStringOnce . "git.email" "Git email" -}}
+
email = {{ $gitEmail | quote }}
+
{{ $sshSigningKeyOpId := promptStringOnce . "git.sshSigningKeyOpId" "1Password ID for SSH signing key (e.g. op://Private/abcd)" -}}
+
sshSigningKeyOpId = {{ trimAll "\"" $sshSigningKeyOpId | quote }}
-1
.chezmoidata.toml
···
editor = "hx"
-
opDir = "/opt/1Password"