diff --git a/home/.chezmoiscripts/universal/run_onchange_after_14-install-aqua-packages.tmpl b/home/.chezmoiscripts/universal/run_onchange_after_14-install-aqua-packages.tmpl index 7a6acd3e..430208b5 100644 --- a/home/.chezmoiscripts/universal/run_onchange_after_14-install-aqua-packages.tmpl +++ b/home/.chezmoiscripts/universal/run_onchange_after_14-install-aqua-packages.tmpl @@ -1,23 +1,13 @@ -{{- if false }} #!/usr/bin/env bash -set -eufo pipefail - {{ includeTemplate "universal/profile" }} {{ includeTemplate "universal/logg" }} -{{- $files := list -}} -{{- range $path := glob (list .chezmoi.sourceDir "private_dot_config/aqua/**/*.yaml.tmpl" | join "/") }} -{{- $files = concat $files (list (include $path)) -}} -{{- end }} -# aqua.yaml.tmpl hash: {{ $files | join "" | sha256sum }} -if ! command -v aqua >/dev/null 2>&1; then - logg info 'Installing Aqua' - curl -sSfL https://raw.githubusercontent.com/aquaproj/aqua-installer/v1.0.0/aqua-installer | bash +if command -v aqua > /dev/null; then + logg info 'Updating Aqua' + aqua update-aqua + logg info 'Installing Aqua dependencies (if any are defined)' + aqua install -a +else + logg info 'Skipping aqua install script because aqua was not installed' fi - -logg info 'Updating Aqua' -aqua update-aqua -logg info 'Installing Aqua dependencies (if any are defined)' -aqua install -a -{{ end -}} diff --git a/home/.chezmoiscripts/universal/run_onchange_after_14-warp.tmpl b/home/.chezmoiscripts/universal/run_onchange_after_14-warp.tmpl index cc4506be..2df8623d 100644 --- a/home/.chezmoiscripts/universal/run_onchange_after_14-warp.tmpl +++ b/home/.chezmoiscripts/universal/run_onchange_after_14-warp.tmpl @@ -1,6 +1,9 @@ {{- if (ne .host.distro.family "windows") -}} #!/usr/bin/env bash +{{ includeTemplate "universal/profile" }} +{{ includeTemplate "universal/logg" }} + ### Configure CloudFlare WARP (if not WSL and warp-cli is installed) if [[ ! "$(test -d /proc && grep Microsoft /proc/version > /dev/null)" ]] && command -v warp-cli > /dev/null; then ### Register CloudFlare WARP diff --git a/home/.chezmoiscripts/universal/run_onchange_after_24-vpn-darwin.tmpl b/home/.chezmoiscripts/universal/run_onchange_after_24-vpn-darwin.tmpl index 370b7507..9c43e407 100644 --- a/home/.chezmoiscripts/universal/run_onchange_after_24-vpn-darwin.tmpl +++ b/home/.chezmoiscripts/universal/run_onchange_after_24-vpn-darwin.tmpl @@ -1,4 +1,4 @@ -{{- if eq .host.distro.family "darwin" -}} +{{- if (eq .host.distro.family "darwin") -}} #!/usr/bin/env bash {{ includeTemplate "universal/profile" }} diff --git a/home/.chezmoiscripts/universal/run_onchange_after_40-chrome.tmpl b/home/.chezmoiscripts/universal/run_onchange_after_40-chrome.tmpl index 7e9957a4..4202167c 100644 --- a/home/.chezmoiscripts/universal/run_onchange_after_40-chrome.tmpl +++ b/home/.chezmoiscripts/universal/run_onchange_after_40-chrome.tmpl @@ -24,7 +24,7 @@ for POLICY_DIR in "/opt/google/chrome/policies" "/etc/chromium/policies" "/etc/b done ### Add Chrome extension JSON -for EXTENSION_DIR in "/opt/google/chrome/extensions" "/etc/chromium/extensions" "/etc/brave/extensions" "$HOME/Library/Application Support/Google/Chrome/External Extensions" "$HOME/Library/Application Support/Microsoft/Edge/External Extensions" "$HOME/Library/Application Support/BraveSoftware/Brave-Browser/External Extensions" ; do +for EXTENSION_DIR in "/opt/google/chrome/extensions" "/etc/chromium/extensions" "/etc/brave/extensions" "$HOME/Library/Application Support/Google/Chrome/External Extensions" "$HOME/Library/Application Support/Microsoft/Edge/External Extensions" "$HOME/Library/Application Support/BraveSoftware/Brave-Browser/External Extensions"; do ### Ensure program-type is installed if [ -d "$(dirname "$EXTENSION_DIR")" ]; then ### Ensure extension directory exists diff --git a/home/.chezmoiscripts/universal/run_onchange_after_40-firefox.tmpl b/home/.chezmoiscripts/universal/run_onchange_after_40-firefox.tmpl index c0e9367f..86af6ad7 100644 --- a/home/.chezmoiscripts/universal/run_onchange_after_40-firefox.tmpl +++ b/home/.chezmoiscripts/universal/run_onchange_after_40-firefox.tmpl @@ -5,7 +5,6 @@ {{ includeTemplate "universal/logg" }} # Firefox plugins: {{ list (.firefoxAddOns | toString | replace "[" "" | replace "]" "") | uniq | join " " }} -# ### Installs the Firefox Profile Connector on Linux systems (Snap / Flatpak installs are not included in this function, but instead inline below) function installFirefoxProfileConnector() { diff --git a/home/.chezmoiscripts/universal/run_onchange_after_80-bash-completions.tmpl b/home/.chezmoiscripts/universal/run_onchange_after_80-bash-completions.tmpl index d6747a8d..176649e0 100644 --- a/home/.chezmoiscripts/universal/run_onchange_after_80-bash-completions.tmpl +++ b/home/.chezmoiscripts/universal/run_onchange_after_80-bash-completions.tmpl @@ -18,6 +18,13 @@ COMPLETION_DIR="$HOME/.local/share/bash-completion/completions" mkdir -p "$COMPLETION_DIR" FALLBACK_URL="https://gitlab.com/megabyte-labs/misc/dotfiles/-/raw/master/dotfiles/.local/share/bash-completion/completions" +### Aqua +if command -v aqua &> /dev/null; then + aqua completion bash > "$COMPLETION_DIR/aqua.bash" +elif [ -f "$COMPLETION_DIR/aqua.bash" ]; then + rm "$COMPLETION_DIR/aqua.bash" +fi + ### Deno if command -v deno > /dev/null; then deno completions bash > "$COMPLETION_DIR/deno.bash" diff --git a/home/dot_config/aqua/aqua.yaml b/home/dot_config/aqua/aqua.yaml new file mode 100644 index 00000000..880fce4d --- /dev/null +++ b/home/dot_config/aqua/aqua.yaml @@ -0,0 +1,12 @@ +--- +# aqua - Declarative CLI Version Manager +# https://aquaproj.github.io/ +# checksum: +# # https://aquaproj.github.io/docs/reference/checksum/ +# enabled: true +# require_checksum: true +registries: +- type: standard + ref: v3.149.0 # renovate: depName=aquaproj/aqua-registry +packages: +- name: google/yamlfmt@v0.8.0 \ No newline at end of file diff --git a/software.yml b/software.yml index 5b8b45d3..0e5613ba 100644 --- a/software.yml +++ b/software.yml @@ -483,6 +483,7 @@ softwarePackages: brew: aquaproj/aqua/aqua binary:linux: https://github.com/aquaproj/aqua/releases/download/v2.0.0-0/aqua_linux_amd64.tar.gz binary:windows: https://github.com/aquaproj/aqua/releases/download/v2.0.0-0/aqua_windows_amd64.tar.gz + go: github.com/aquaproj/aqua/v2/cmd/aqua@latest _type: cli argo-cli: _bin: argocd