From b7db35d8d3a444c261080ff60575b97a476b802b Mon Sep 17 00:00:00 2001 From: David Personette Date: Sat, 10 Feb 2024 00:38:37 +0000 Subject: [PATCH 1/2] Update custom.just with the ability to set Prompt terminal transparency --- just/custom.just | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/just/custom.just b/just/custom.just index 1121cd02f34..d8f4d5b00c1 100644 --- a/just/custom.just +++ b/just/custom.just @@ -184,6 +184,23 @@ nix-devbox-global: echo 'run "devbox global run install-hook-zsh" to configure zsh shell' echo 'run "devbox global run" to see other available configuration commands' +# Prompt terminal transparency +prompt-transparency opacity="0.85": + #!/usr/bin/env bash + set -euxo pipefail + if [[ -n "$(echo "{{ opacity }}" | grep -v '^[.0-9]*$')" ]]; then + printf "Value must be numeric: %s.\n" "{{ opacity }}" + elif [[ $(echo "0<{{ opacity }} && 1>{{ opacity }}" | bc -q) -eq 1 ]]; then + raw="$(gsettings get org.gnome.Prompt profile-uuids)" + uuids="$(sed -En 's|[^0-9a-z]*||g; s|([0-9a-z]{32})|\1\n|gp' <<<${raw})" + for i in ${uuids}; do + location="org.gnome.Prompt.Profile:/org/gnome/Prompt/Profiles/${i}/" + gsettings set "${location}" opacity "{{ opacity }}"; done + printf "Prompt opacity is now %s.\n" "{{ opacity }}" + else + printf "Value must be between 0 and 1: %s.\n" "{{ opacity }}" + fi + # Run pytorch pytorch: echo 'Follow the prompts and check the tutorial: https://docs.anaconda.com/free/anaconda/jupyter-notebooks/' From 0c21076323560c0e060c54c28e2f462282d61265 Mon Sep 17 00:00:00 2001 From: David Personette Date: Sat, 10 Feb 2024 02:43:13 +0000 Subject: [PATCH 2/2] fix: set default modified Prompt transparency to 0.95 by default --- just/custom.just | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/just/custom.just b/just/custom.just index d8f4d5b00c1..8a57bfaa97f 100644 --- a/just/custom.just +++ b/just/custom.just @@ -185,7 +185,7 @@ nix-devbox-global: echo 'run "devbox global run" to see other available configuration commands' # Prompt terminal transparency -prompt-transparency opacity="0.85": +prompt-transparency opacity="0.95": #!/usr/bin/env bash set -euxo pipefail if [[ -n "$(echo "{{ opacity }}" | grep -v '^[.0-9]*$')" ]]; then