Update chezmoi config and using toml

This commit is contained in:
Eric Renfro 2023-12-26 16:14:21 -05:00
parent e87e2295e6
commit d60bca0137
Signed by: psi-jack
SSH key fingerprint: SHA256:1TKB8Z257L8EHK8GWNxKgMhD8a+FAR+f+j3nnlcuNVM
2 changed files with 35 additions and 33 deletions

35
.chezmoi.toml.tmpl Normal file
View file

@ -0,0 +1,35 @@
{{- $gitname := promptStringOnce . "gitname" "Git Name" -}}
{{- $gitmail := promptStringOnce . "gitmail" "Git Mail Address" -}}
{{- $osid := chezmoi.os -}}
{{- if .chezmoi.osRelease -}}
{{- if hasKey .chezmoi.osRelease "id" -}}
{{- $osid = printf "%s-%s" .chezmoi.os .chezmoi.osRelease.id -}}
{{- end -}}
{{- end -}}
pager = "less -R"
encryption = "age"
[data]
gitname = {{ $gitname | quote }}
gitmail = {{ $gitmail | quote }}
osid = {{ $osid | quote }}
[age]
identity = ~"~/.config/sops/keys.txt"
recipient = "age1fc7myuewzdr7rvqr9fl3x3jwky3j4gp92hxguf3dlgnesm9s9e8q45xmp2"
[git]
autoCommit = false
autoPush = false
autoAdd = true
[diff]
exclude = ["externals"]
{{- if lookPath "nvim" }}
[merge]
command = "nvim"
args = ["-d"]
{{- end }}

View file

@ -1,33 +0,0 @@
{{- $personal := promptBool "Personal?" -}}{{/* true if this is a personal machine */}}
{{- if eq $personal true -}}
{{- $email := promptString "Email?" -}}
{{- $work := false -}}
{{- else -}}
{{- $email = promptString "Email?" -}}
{{- $work := promptBool "Work?" -}}
{{- end -}}
sourceDir: {{ .chezmoi.SourceDir | quote }}
data:
name: "Eric Renfro"
email: {{ $email | quote }}
is:
personal: {{ $personal -}}
work: {{ $work -}}
battlestation: false
headless: true
theme: "erenfro"
programs:
terminal: alacritty
editor: micro
visual: less
browser: firefox
font:
term:
name: "Hack Nerd Font"
size: 12.0
encryption: age
age:
recipient: "age1fc7myuewzdr7rvqr9fl3x3jwky3j4gp92hxguf3dlgnesm9s9e8q45xmp2"
identity: "~/.config/sops/keys.txt"