syntax improvements

This commit is contained in:
2021-01-14 10:37:13 +01:00
parent 4cf9387cb8
commit f49c74f12b

View File

@@ -1,6 +1,6 @@
# vim: syntax=bash: # vim: syntax=bash:
eval "reset_esc=\"\\e[0m\"" reset_esc='\e[0m'
# applies the given color id, executes the command, then resets the color # applies the given color id, executes the command, then resets the color
function colout() { function colout() {
@@ -49,7 +49,7 @@ function dispcollist() {
function colthis { function colthis {
local name="$1" local name="$1"
shift shift
eval "printf \"\${${name}_esc}$@$reset_esc\"" eval "printf \"%s\" \"\${${name}_esc}$@$reset_esc\""
} }
# default colors # default colors