dotfiles/home/.chezmoi.toml.tmpl
2023-03-04 18:35:16 +08:00

45 lines
1.2 KiB
Cheetah

{{- $email := "" -}}
{{- if hasKey . "email" -}}
{{- $email = .email -}}
{{- else -}}
{{- $email = promptStringOnce . "email" "email address" -}}
{{ end }}
{{- $gitUser := "" -}}
{{- if hasKey . "gitUser" -}}
{{- $gitUser = .gitUser -}}
{{- else -}}
{{- $gitUser = promptStringOnce . "gitUser" "git username" -}}
{{- end -}}
{{- $jsLinter := promptStringOnce . "jsLinter" "js linter" "standard" -}}
{{- if eq $jsLinter "" -}}
{{- $jsLinter = "standard" -}}
{{- end -}}
{{- $jsFixer := promptStringOnce . "jsFixer" "js fixer" "standard" -}}
{{- if eq $jsFixer "" -}}
{{- $jsFixer = "standard" -}}
{{- end -}}
{{- $installGo := promptBoolOnce . "installGo" "install golang bin" true -}}
{{- $installNode := promptBoolOnce . "installNode" "install nodejs bin" true -}}
{{- $installRust := promptBoolOnce . "installRust" "install rust bin" true -}}
{{- $enableTmux := promptBoolOnce . "enableTmux" "install enable tmux autostart" true -}}
[data.shell]
tmux = {{ $enableTmux }}
[data.gitconfig]
email = {{ $email | quote }}
username = {{ $gitUser | quote }}
[data.nvim]
js_linter = {{ $jsLinter | quote }}
js_fixer = {{ $jsFixer | quote }}
[data.dev]
golang = {{ $installGo }}
nodejs = {{ $installNode }}
rust = {{ $installRust }}