From 0ecfe53b2d271133fac36de11ecfc0f7e47840f0 Mon Sep 17 00:00:00 2001 From: "Douglas B. Rumbaugh" Date: Sat, 6 Jun 2026 12:27:03 -0400 Subject: Initial version complete I dusted this off after years and had Claude finish it for me. caveat emptor: this is largely (though not entirely) LLM generated as of this commit --- ves-show.sh | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 ves-show.sh (limited to 'ves-show.sh') diff --git a/ves-show.sh b/ves-show.sh new file mode 100644 index 0000000..b50487a --- /dev/null +++ b/ves-show.sh @@ -0,0 +1,25 @@ +#!/bin/sh +# +# Print the variables stored in an sh-ves environment, one VAR=value per +# line. With no argument, shows the currently active environment. +# +ves_show() { + env="" + if [ "$#" -ge 1 ]; then + env="$1" + fi + + if ! env=$(_shves_resolve_env "$env"); then + return 1 + fi + + while IFS= read -r line; do + case $line in + export_var:*) + printf "%s\n" "${line#export_var:}" + ;; + esac + done < "$SHVES_ENV_DIR/$env" + + return 0 +} -- cgit v1.2.3