diff --git a/src/.chezmoi.toml.tmpl b/src/.chezmoi.toml.tmpl new file mode 100644 index 0000000..08bd125 --- /dev/null +++ b/src/.chezmoi.toml.tmpl @@ -0,0 +1,5 @@ +{{- $systemprofilechoices := list "DEFAULT" "SLIM" "MINIMAL" -}} +{{- $systemprofile := promptChoiceOnce . "systemprofile" "Select a system profile (use capital letter)" $systemprofilechoices "SLIM" -}} + +[data] +systemprofile = {{- $systemprofile | quote -}} diff --git a/src/dot_config/literal_dot_profile.example b/src/dot_config/literal_dot_profile.example deleted file mode 100644 index cb6f3b5..0000000 --- a/src/dot_config/literal_dot_profile.example +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/sh -# Profile that enables/disables certain features based on the device -# Everything might need to be restarted for this to take effect. - -## ---------- -## IMPORTANT! -## ---------- -## Copy this to '~/.config/dot_profile'. - -# Profiles -# -------- -# DEFAULT: -# Everything's enabled. -# SLIM: -# Try to reduce bloat; turn off expensive plugins and eye-candy. -# MINIMAL: -# Nothing is launched automatically, and no plugins are installed. - -export SYSTEM_PROFILE="DEFAULT" diff --git a/src/dot_config/vars b/src/dot_config/vars.tmpl similarity index 94% rename from src/dot_config/vars rename to src/dot_config/vars.tmpl index 50dc7a1..7621d0c 100644 --- a/src/dot_config/vars +++ b/src/dot_config/vars.tmpl @@ -70,11 +70,7 @@ if [ -r "$XDG_CONFIG_HOME"/identity ]; then fi # Profile to enable/disable features on certain devices -if [ ! -f "$XDG_CONFIG_HOME"/dot_profile ]; then - export SYSTEM_PROFILE="SLIM" -else - . "$XDG_CONFIG_HOME"/dot_profile -fi +export SYSTEM_PROFILE={{ .systemprofile | quote }} # Typst root export TYPST_ROOT="$HOME/nt"