fix: escaping in options (#298)

* fix: escaping in options

* chore: ignore shellcheck warning
This commit is contained in:
vdbe 2024-08-23 09:13:18 +00:00 committed by GitHub
parent a71f3c039b
commit 9b57c20020
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -66,7 +66,7 @@ get_tmux_batch_option() {
for option_index in "${!tmux_batch_options[@]}"; do
IFS="" read -r read_option read_value <<<"${tmux_batch_options[$option_index]}"
if [[ "$read_option" == "$option" ]]; then
echo -e "$read_value"
echo "$read_value"
return
fi
done
@ -117,8 +117,8 @@ set_tmux_batch_option() {
run_tmux_batch_commands() {
local temp
# shellcheck disable=SC2048,SC2086
while IFS=' ' read -r option value; do
# shellcheck disable=SC2048,SC2086,SC2162
while IFS=' ' read option value; do
if [ -n "$value" ]; then
if [ "$value" = "null" ]; then
set_tmux_batch_option "$option" ""