From d86f4fb7239fd73ac9f2b966bc0b1adeb8bd6517 Mon Sep 17 00:00:00 2001 From: ADAM David Alan Martin Date: Tue, 22 Jul 2025 17:40:15 -0400 Subject: [PATCH] Starting a bash-curses thing Vulgarity, cursing... get it? --- bin/vulgar.sh | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100755 bin/vulgar.sh diff --git a/bin/vulgar.sh b/bin/vulgar.sh new file mode 100755 index 0000000..8efd016 --- /dev/null +++ b/bin/vulgar.sh @@ -0,0 +1,45 @@ +#!/usr/bin/env bash + +send_os_command() +{ + _splat="" + _suffix="" + while [ -n "${1}" ] + do + [ -n '${_splat}' ] && _splat=${_splat}';' + _splat="${_splat}${1}" + shift 1 + done + echo "]${_splat}${_suffix}" +} + +send_csi_command() +{ + _splat="" + _suffix="${1}" + shift 1 + while [ -n "${1}" ] + do + [ -n '${_splat}' ] && _splat="${_splat}"';' + _splat="${_splat}${1}" + shift 1 + done + echo ${_splat} + echo "[${_splat}${_suffix}" +} + +erase_block() +{ + send_csi_command '${' $* +} + +fill_block() +{ + send_csi_command '$x' $* +} + + + +erase_block 20 20 30 30 +fill_block X 21 21 29 29 +