diff --git a/home/.chezmoiscripts/darwin/run_once_touchid-sudo.sh b/home/.chezmoiscripts/darwin/run_once_touchid-sudo.sh index 6b2c961..2411f26 100644 --- a/home/.chezmoiscripts/darwin/run_once_touchid-sudo.sh +++ b/home/.chezmoiscripts/darwin/run_once_touchid-sudo.sh @@ -1,5 +1,7 @@ #!/bin/sh +{{ if .wheel }} + echo "[INFO] Use TouchID to authenticate before running sudo commands." echo "[WARNING] This operation modifies critical system files." echo " If something goes wrong, you may need to boot into macOS Recovery Mode to restore your system." @@ -14,3 +16,9 @@ echo "" set -x sudo cp ~/.dotfiles/misc/mac/etc/pam.d/sudo /etc/pam.d/sudo set +x + +{{ else }} + +exit 0 # Exit with success status code + +{{ end }} diff --git a/home/.chezmoiscripts/linux/run_once_after_fonts.sh b/home/.chezmoiscripts/linux/run_once_after_fonts.sh deleted file mode 100644 index 0b1efc2..0000000 --- a/home/.chezmoiscripts/linux/run_once_after_fonts.sh +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/sh - -echo "[INFO] Rebuilding fonts cache..." - -fc-cache -fv diff --git a/home/.chezmoiscripts/linux/run_onchange_after_firefox-configs.sh.tmpl b/home/.chezmoiscripts/linux/run_onchange_after_firefox-configs.sh.tmpl index c5de4b0..6ad82c2 100644 --- a/home/.chezmoiscripts/linux/run_onchange_after_firefox-configs.sh.tmpl +++ b/home/.chezmoiscripts/linux/run_onchange_after_firefox-configs.sh.tmpl @@ -1,5 +1,10 @@ #!/bin/sh +# misc/firefox/policies.json hash: +# {{ include joinPath .chezmoi.homeDir ".dotfiles" "misc/firefox/policies.json" | sha256sum }} +# misc/firefox/search.json.mozlz4 hash: +# {{ include joinPath .chezmoi.homeDir ".dotfiles" "misc/firefox/search.json.mozlz4" | sha256sum }} + # Check if firefox is installed if ! command -v firefox &> /dev/null; then echo "[WARNING] Firefox is not installed. Skip this script." diff --git a/home/.chezmoiscripts/linux/run_onchange_after_fonts.sh.tmpl b/home/.chezmoiscripts/linux/run_onchange_after_fonts.sh.tmpl new file mode 100644 index 0000000..6c33e39 --- /dev/null +++ b/home/.chezmoiscripts/linux/run_onchange_after_fonts.sh.tmpl @@ -0,0 +1,8 @@ +#!/bin/sh + +# .chezmoiexternals/linux-fonts.toml hash: +# {{ include ".chezmoiexternals/linux-fonts.toml" | sha256sum }} + +echo "[INFO] Rebuilding fonts cache..." + +fc-cache -fv diff --git a/home/dot_gitconfig b/home/dot_gitconfig.tmpl similarity index 100% rename from home/dot_gitconfig rename to home/dot_gitconfig.tmpl