From acfdf2da5ba285f23dda77c63f2534c8ac454d2e Mon Sep 17 00:00:00 2001 From: Brian Zalewski Date: Fri, 2 Dec 2022 07:18:16 +0000 Subject: [PATCH] Update .local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_after_99_bootstrap-zsh-plugins.tmpl, .local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_after_10_install-aqua-packages.sh.tmpl, .local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_after_50-crontab.tmpl, .local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_before_5-install-homebrew.tmpl, .local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_before_8-install-zx.tmpl, .local/share/chezmoi/home/.chezmoiscripts/windows/run_onchange_before_10-install-windows-dependencies.tmpl, .local/share/chezmoi/home/.chezmoiscripts/windows/run_onchange_before_11-install-windows-packages.tmpl, .local/share/chezmoi/home/.chezmoiscripts/ubuntu/run_onchange_before_10_install-ubuntu-dependencies.tmpl, .local/share/chezmoi/home/.chezmoiscripts/opensuse/run_onchange_before_11-install-opensuse-software.tmpl, .local/share/chezmoi/home/.chezmoiscripts/freebsd/run_onchange_before_11-install-freebsd-packages.tmpl, .local/share/chezmoi/home/.chezmoiscripts/fedora/run_onchange_before_10-install-fedora-dependencies.tmpl, .local/share/chezmoi/home/.chezmoiscripts/debian/run_onchange_before_10-install-debian-dependencies.tmpl, .local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_before_10_install-darwin-dependencies.tmpl, .local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_after_set-wallpaper.tmpl, .local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_after_20-ensure-zsh-macos.tmpl, .local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_after_10_configure-macos.tmpl, .local/share/chezmoi/home/.chezmoiscripts/centos/run_onchange_before_10-install-centos-dependencies.tmpl, .local/share/chezmoi/home/.chezmoiscripts/archlinux/run_onchange_before_10_install-archlinux-dependencies.tmpl, .local/share/chezmoi/home/Library/Fonts/run_onchange_after_add-fonts.tmpl --- ...n_onchange_before_10_install-archlinux-dependencies.tmpl | 2 ++ .../run_onchange_before_10-install-centos-dependencies.tmpl | 2 ++ .../darwin/run_onchange_after_10_configure-macos.tmpl | 2 ++ .../darwin/run_onchange_after_20-ensure-zsh-macos.tmpl | 2 ++ .../darwin/run_onchange_after_set-wallpaper.tmpl | 2 ++ .../run_onchange_before_10_install-darwin-dependencies.tmpl | 2 ++ .../run_onchange_before_10-install-debian-dependencies.tmpl | 2 ++ .../run_onchange_before_10-install-fedora-dependencies.tmpl | 2 ++ .../run_onchange_before_11-install-freebsd-packages.tmpl | 2 ++ .../run_onchange_before_11-install-opensuse-software.tmpl | 2 ++ .../run_onchange_before_10_install-ubuntu-dependencies.tmpl | 2 ++ .../run_onchange_after_10_install-aqua-packages.sh.tmpl | 4 ++-- .../universal/run_onchange_after_50-crontab.tmpl | 5 ++--- .../run_onchange_after_99_bootstrap-zsh-plugins.tmpl | 6 +++--- .../universal/run_onchange_before_5-install-homebrew.tmpl | 2 ++ .../universal/run_onchange_before_8-install-zx.tmpl | 2 ++ ...run_onchange_before_10-install-windows-dependencies.tmpl | 4 ++-- .../run_onchange_before_11-install-windows-packages.tmpl | 4 ++-- .../home/Library/Fonts/run_onchange_after_add-fonts.tmpl | 2 +- 19 files changed, 38 insertions(+), 13 deletions(-) diff --git a/.local/share/chezmoi/home/.chezmoiscripts/archlinux/run_onchange_before_10_install-archlinux-dependencies.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/archlinux/run_onchange_before_10_install-archlinux-dependencies.tmpl index ac7dae47..52cc3ebe 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/archlinux/run_onchange_before_10_install-archlinux-dependencies.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/archlinux/run_onchange_before_10_install-archlinux-dependencies.tmpl @@ -1,3 +1,4 @@ +{{- if .host.distro.id "archlinux" }} #!/usr/bin/env bash # universal/essential-packages hash: {{ include (joinPath ".chezmoitemplates" "universal" "essential-packages") | sha256sum }} @@ -40,3 +41,4 @@ if ! command -v yay > /dev/null; then logg 'Installing yay via `sudo makepkg -si`' sudo makepkg -si fi +{{ end -}} diff --git a/.local/share/chezmoi/home/.chezmoiscripts/centos/run_onchange_before_10-install-centos-dependencies.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/centos/run_onchange_before_10-install-centos-dependencies.tmpl index 55e45711..d3e5e5d1 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/centos/run_onchange_before_10-install-centos-dependencies.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/centos/run_onchange_before_10-install-centos-dependencies.tmpl @@ -1,3 +1,4 @@ +{{- if .host.distro.id "centos" }} #!/usr/bin/env bash # universal/essential-packages hash: {{ include (joinPath ".chezmoitemplates" "universal" "essential-packages") | sha256sum }} @@ -22,3 +23,4 @@ logg info 'Dependencies: {{ $packages | sortAlpha | uniq | join " " -}}' ### Install base dependencies sudo dnf install -y {{ $packages | sortAlpha | uniq | join " " -}} +{{ end -}} diff --git a/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_after_10_configure-macos.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_after_10_configure-macos.tmpl index aadea449..023dcf11 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_after_10_configure-macos.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_after_10_configure-macos.tmpl @@ -1,3 +1,4 @@ +{{- if .host.distro.family "darwin" }} #!/usr/bin/env bash set -x @@ -938,3 +939,4 @@ done logg 'Done applying macOS settings' logg info 'Some of these changes may require a logout/restart to take effect' +{{ end -}} diff --git a/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_after_20-ensure-zsh-macos.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_after_20-ensure-zsh-macos.tmpl index 736aed91..11f9df69 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_after_20-ensure-zsh-macos.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_after_20-ensure-zsh-macos.tmpl @@ -1,3 +1,4 @@ +{{- if .host.distro.family "darwin" }} #!/usr/bin/env bash {{- includeTemplate "universal/logg" }} @@ -14,3 +15,4 @@ if [[ ! -e /usr/local/bin/zsh ]]; then fi {{- end -}} {{- end }} +{{ end -}} diff --git a/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_after_set-wallpaper.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_after_set-wallpaper.tmpl index 95656d7d..70321825 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_after_set-wallpaper.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_after_set-wallpaper.tmpl @@ -1,3 +1,4 @@ +{{- if .host.distro.family "darwin" }} #!/usr/bin/env bash # Betelgeuse-macOS wallpaper hash: {{ include (joinPath .chezmoi.homeDir ".local" "src" "betelgeuse" "share" "wallpapers" "Betelgeuse-macOS" "contents" "source.png") | sha256sum }} @@ -8,3 +9,4 @@ if command -v m > /dev/null && [ -f "$HOME/.local/src/betelgeuse/share/wallpaper else logg warn 'Either `m` or the macOS default wallpaper is missing.' fi +{{ end -}} diff --git a/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_before_10_install-darwin-dependencies.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_before_10_install-darwin-dependencies.tmpl index 2a605c39..450ede48 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_before_10_install-darwin-dependencies.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/darwin/run_onchange_before_10_install-darwin-dependencies.tmpl @@ -1,3 +1,4 @@ +{{- if .host.distro.family "darwin" }} #!/usr/bin/env bash # darwin/Brewfile hash: {{ include (joinPath ".chezmoitemplates" "darwin" "Brewfile") | sha256sum }} @@ -16,3 +17,4 @@ if command -v brew > /dev/null; then else logg error '`brew` was not found in the PATH' fi +{{ end -}} diff --git a/.local/share/chezmoi/home/.chezmoiscripts/debian/run_onchange_before_10-install-debian-dependencies.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/debian/run_onchange_before_10-install-debian-dependencies.tmpl index 0e2bd2ea..ca141e52 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/debian/run_onchange_before_10-install-debian-dependencies.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/debian/run_onchange_before_10-install-debian-dependencies.tmpl @@ -1,3 +1,4 @@ +{{- if .host.distro.id "debian" }} #!/usr/bin/env bash # universal/essential-packages hash: {{ include (joinPath ".chezmoitemplates" "universal" "essential-packages") | sha256sum }} @@ -43,3 +44,4 @@ logg info 'Dependencies: {{ $packages | sortAlpha | uniq | join " " -}}' sudo apt-get update sudo apt-get install -y --no-install-recommends {{ $packages | sortAlpha | uniq | join " " -}} +{{ end -}} diff --git a/.local/share/chezmoi/home/.chezmoiscripts/fedora/run_onchange_before_10-install-fedora-dependencies.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/fedora/run_onchange_before_10-install-fedora-dependencies.tmpl index 55e45711..367b264a 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/fedora/run_onchange_before_10-install-fedora-dependencies.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/fedora/run_onchange_before_10-install-fedora-dependencies.tmpl @@ -1,3 +1,4 @@ +{{- if .host.distro.id "fedora" }} #!/usr/bin/env bash # universal/essential-packages hash: {{ include (joinPath ".chezmoitemplates" "universal" "essential-packages") | sha256sum }} @@ -22,3 +23,4 @@ logg info 'Dependencies: {{ $packages | sortAlpha | uniq | join " " -}}' ### Install base dependencies sudo dnf install -y {{ $packages | sortAlpha | uniq | join " " -}} +{{ end -}} \ No newline at end of file diff --git a/.local/share/chezmoi/home/.chezmoiscripts/freebsd/run_onchange_before_11-install-freebsd-packages.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/freebsd/run_onchange_before_11-install-freebsd-packages.tmpl index 7fac7b91..1642ea69 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/freebsd/run_onchange_before_11-install-freebsd-packages.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/freebsd/run_onchange_before_11-install-freebsd-packages.tmpl @@ -1,3 +1,4 @@ +{{- if .host.distro.id "freebsd" }} #!/usr/bin/env bash # universal/essential-packages hash: {{ include (joinPath ".chezmoitemplates" "universal" "essential-packages") | sha256sum }} @@ -22,3 +23,4 @@ logg info 'Dependencies: {{ $packages | sortAlpha | uniq | join " " -}}' ### Install base dependencies sudo pkg install -y {{ $packages | sortAlpha | uniq | join " " -}} +{{ end -}} diff --git a/.local/share/chezmoi/home/.chezmoiscripts/opensuse/run_onchange_before_11-install-opensuse-software.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/opensuse/run_onchange_before_11-install-opensuse-software.tmpl index cffead5a..df804576 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/opensuse/run_onchange_before_11-install-opensuse-software.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/opensuse/run_onchange_before_11-install-opensuse-software.tmpl @@ -1,3 +1,4 @@ +{{- if .host.distro.id "opensuse" }} #!/usr/bin/env bash # universal/essential-packages hash: {{ include (joinPath ".chezmoitemplates" "universal" "essential-packages") | sha256sum }} @@ -22,3 +23,4 @@ logg info 'Dependencies: {{ $packages | sortAlpha | uniq | join " " -}}' ### Install base dependencies sudo zypper install -y {{ $packages | sortAlpha | uniq | join " " -}} +{{ end -}} \ No newline at end of file diff --git a/.local/share/chezmoi/home/.chezmoiscripts/ubuntu/run_onchange_before_10_install-ubuntu-dependencies.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/ubuntu/run_onchange_before_10_install-ubuntu-dependencies.tmpl index 13b2c5a6..69e55837 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/ubuntu/run_onchange_before_10_install-ubuntu-dependencies.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/ubuntu/run_onchange_before_10_install-ubuntu-dependencies.tmpl @@ -1,3 +1,4 @@ +{{- if .host.distro.id "ubuntu" }} #!/usr/bin/env bash # universal/essential-packages hash: {{ include (joinPath ".chezmoitemplates" "universal" "essential-packages") | sha256sum }} @@ -43,3 +44,4 @@ logg info 'Dependencies: {{ $packages | sortAlpha | uniq | join " " -}}' sudo apt-get update sudo apt-get install -y --no-install-recommends {{ $packages | sortAlpha | uniq | join " " -}} +{{ end -}} diff --git a/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_after_10_install-aqua-packages.sh.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_after_10_install-aqua-packages.sh.tmpl index 837f9eae..796e484a 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_after_10_install-aqua-packages.sh.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_after_10_install-aqua-packages.sh.tmpl @@ -1,5 +1,5 @@ -#!/usr/bin/env bash {{- if false }} +#!/usr/bin/env bash set -eufo pipefail @@ -20,4 +20,4 @@ logg info 'Updating Aqua' aqua update-aqua logg info 'Installing Aqua dependencies (if any are defined)' aqua install -a -{{- end }} +{{ end -}} diff --git a/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_after_50-crontab.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_after_50-crontab.tmpl index 6e545599..4195133c 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_after_50-crontab.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_after_50-crontab.tmpl @@ -1,5 +1,5 @@ -#!/usr/bin/env sh {{- if false }} +#!/usr/bin/env sh # crontab config hash: {{ include (joinPath .chezmoi.homeDir ".config" "crontab" "config")| sha256sum }} @@ -8,5 +8,4 @@ logg 'Installing crontab jobs' crontab < "$XDG_CONFIG_HOME/crontab/config" -{{- end }} -# TODO +{{ end -}} diff --git a/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_after_99_bootstrap-zsh-plugins.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_after_99_bootstrap-zsh-plugins.tmpl index dcd9f290..381471c6 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_after_99_bootstrap-zsh-plugins.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_after_99_bootstrap-zsh-plugins.tmpl @@ -1,5 +1,5 @@ -#!/usr/bin/env bash {{- if eq .host.headless true }} +#!/usr/bin/env bash # .zshrc hash: {{ include (joinPath .chezmoi.homeDir ".zshrc")| sha256sum }} @@ -8,7 +8,7 @@ ### Initialize ZSH so plugin bootstrap process is done ahead of time if command -v zsh > /dev/null; then - logg 'Bootstrapping ZSH plugin system' + # logg 'Bootstrapping ZSH plugin system' exec zsh && exit 0 fi -{{- end -}} +{{ end -}} diff --git a/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_before_5-install-homebrew.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_before_5-install-homebrew.tmpl index 6ec672aa..161b25a7 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_before_5-install-homebrew.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_before_5-install-homebrew.tmpl @@ -1,3 +1,4 @@ +{{- if (ne .host.distro.family "windows") }} #!/usr/bin/env bash {{- includeTemplate "universal/profile" }} @@ -32,3 +33,4 @@ ensurePackageManagerHomebrew() { fi } ensurePackageManagerHomebrew +{{ end -}} diff --git a/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_before_8-install-zx.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_before_8-install-zx.tmpl index 0347f78b..bab34053 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_before_8-install-zx.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/universal/run_onchange_before_8-install-zx.tmpl @@ -1,3 +1,4 @@ +{{- if (ne .host.distro.family "windows") }} #!/usr/bin/env bash {{- includeTemplate "universal/profile" }} @@ -49,3 +50,4 @@ if ! command -v zx > /dev/null; then else logg '`zx` is already installed' fi +{{ end -}} \ No newline at end of file diff --git a/.local/share/chezmoi/home/.chezmoiscripts/windows/run_onchange_before_10-install-windows-dependencies.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/windows/run_onchange_before_10-install-windows-dependencies.tmpl index 0eec2b4a..f77780d6 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/windows/run_onchange_before_10-install-windows-dependencies.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/windows/run_onchange_before_10-install-windows-dependencies.tmpl @@ -1,3 +1,3 @@ +{{- if (eq .host.distro.family "windows") }} #!/usr/bin/env bash -{{- if eq .host.distro.id "windows" }} -{{- end }} +{{ end -}} diff --git a/.local/share/chezmoi/home/.chezmoiscripts/windows/run_onchange_before_11-install-windows-packages.tmpl b/.local/share/chezmoi/home/.chezmoiscripts/windows/run_onchange_before_11-install-windows-packages.tmpl index 0eec2b4a..f77780d6 100644 --- a/.local/share/chezmoi/home/.chezmoiscripts/windows/run_onchange_before_11-install-windows-packages.tmpl +++ b/.local/share/chezmoi/home/.chezmoiscripts/windows/run_onchange_before_11-install-windows-packages.tmpl @@ -1,3 +1,3 @@ +{{- if (eq .host.distro.family "windows") }} #!/usr/bin/env bash -{{- if eq .host.distro.id "windows" }} -{{- end }} +{{ end -}} diff --git a/.local/share/chezmoi/home/Library/Fonts/run_onchange_after_add-fonts.tmpl b/.local/share/chezmoi/home/Library/Fonts/run_onchange_after_add-fonts.tmpl index 3976ecf6..25d434a2 100644 --- a/.local/share/chezmoi/home/Library/Fonts/run_onchange_after_add-fonts.tmpl +++ b/.local/share/chezmoi/home/Library/Fonts/run_onchange_after_add-fonts.tmpl @@ -13,7 +13,7 @@ find "$HOME/.local/share/fonts" -type f | while read FONT_FILE; do BASENAME="$(basename "$FONT_FILE")" if [ ! -f "$HOME/Library/Fonts/$BASENAME" ] || [ "$(openssl sha256 "$HOME/Library/Fonts/$BASENAME" | sed 's/.*= //')" != "$(openssl sha256 "$FONT_FILE" | sed 's/.*= //')" ]; then - logg info 'Adding `'"$BASENAME"'` to ~/Library/Fonts' + logg info 'Adding '"$BASENAME"' to ~/Library/Fonts' cp "$FONT_FILE" "$HOME/Library/Fonts/$BASENAME" fi done