48 lines
1.9 KiB
Cheetah
48 lines
1.9 KiB
Cheetah
{{- $name := promptStringOnce . "name" "請輸入您的姓名" -}}
|
|
{{- $email := promptStringOnce . "email" "輸入您的Email地址" -}}
|
|
{{- $signingkey := promptStringOnce . "signingkey" "輸入您的GPG金鑰ID (若不使用,直接留空。可從 gpg --list-secret-keys --keyid-format=long 去找)" -}}
|
|
{{- $ollamaUrl := promptStringOnce . "ollamaUrl" "輸入您的Ollama URL (若不使用,直接留空)" -}}
|
|
{{- $ollamaKey := promptStringOnce . "ollamaKey" "輸入您的Ollama ApiKey (若不使用,直接留空)" -}}
|
|
|
|
{{- $hosttype_choices := list "desktop" "server" "unroot_server" "manual" -}}
|
|
{{- $hosttype := promptChoice "What type of host are you on" $hosttype_choices -}}
|
|
{{- $isServer := true -}}
|
|
{{- $unRootMode := true -}}
|
|
{{- $enableSixel := false -}}
|
|
{{- $enableGUI := false -}}
|
|
{{- $enableYcm := false -}}
|
|
|
|
{{- if eq $hosttype "server" -}}
|
|
{{- $unRootMode = false -}}
|
|
|
|
{{- else if eq $hosttype "desktop" -}}
|
|
{{- $isServer = false -}}
|
|
{{- $unRootMode = false -}}
|
|
{{- $enableSixel = true -}}
|
|
{{- $enableGUI = true -}}
|
|
{{- $enableYcm = true -}}
|
|
|
|
{{- else if eq $hosttype "manual" -}}
|
|
{{- $isServer = promptBool "Does this machine is Server" -}}
|
|
{{- $unRootMode = promptBool "Is enable unRoot local mode (Will install at home directory)" -}}
|
|
{{- $enableSixel = promptBool "Is enable terminal output with sixel" -}}
|
|
{{- $enableGUI = promptBool "Does this machine have a GUI" -}}
|
|
{{- $enableYcm = promptBool "Is enable Vim YCM compatible (Will use 2.7GB)" -}}
|
|
{{ end -}}
|
|
|
|
sourceDir = "~/.local/share/chezmoi"
|
|
|
|
[data]
|
|
name = {{ $name | quote }}
|
|
email = {{ $email | quote }}
|
|
signingkey = {{ $signingkey | quote }}
|
|
serverStyle = {{ $isServer }}
|
|
unRootMode = {{ $unRootMode }}
|
|
enableSixel = {{ $enableSixel }} {{/* TODO: packages.toml還沒處理 */}}
|
|
noGUI = {{ not $enableGUI }}
|
|
enableYcm = {{ $enableYcm }}
|
|
enableOllama = {{ not (not $ollamaUrl) }}
|
|
ollamaUrl = {{ $ollamaUrl | quote }}
|
|
ollamaKey = {{ $ollamaKey | quote }}
|
|
|