From 54e26060f10d887a920d593001598742f9e476a4 Mon Sep 17 00:00:00 2001 From: kx1t Date: Sat, 18 Nov 2023 10:01:09 -0500 Subject: [PATCH] don't auto-capitalize DW_EXTRA_CONFIG --- rootfs/etc/s6-overlay/scripts/30-set-direwolf-params | 3 ++- rootfs/etc/s6-overlay/scripts/direwolf | 8 +++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/rootfs/etc/s6-overlay/scripts/30-set-direwolf-params b/rootfs/etc/s6-overlay/scripts/30-set-direwolf-params index 1d7cddc..feede9c 100755 --- a/rootfs/etc/s6-overlay/scripts/30-set-direwolf-params +++ b/rootfs/etc/s6-overlay/scripts/30-set-direwolf-params @@ -298,7 +298,8 @@ if [[ -n "$DW_EXTRA_CONFIGS" ]]; then # Now loop through each of the elements: for instance in "${configs[@]}" do - instance="${instance^^}" + # don't do this -- instance="${instance^^}" + while [[ "${instance:0:1}" == " " ]]; do instance="${instance:1}"; done param="${instance%%=*}" # all before the first "=" value="${instance#*=}" # all after the first "=" if [[ -z "${instance}" ]]; then diff --git a/rootfs/etc/s6-overlay/scripts/direwolf b/rootfs/etc/s6-overlay/scripts/direwolf index 98b7e8f..37e5936 100755 --- a/rootfs/etc/s6-overlay/scripts/direwolf +++ b/rootfs/etc/s6-overlay/scripts/direwolf @@ -33,9 +33,11 @@ if [[ -n "$DW_DEBUG" ]]; then DW_ARGS+=("-d $DW_DEBUG"); fi if [[ -n "$DW_EXTRA_CMDLINEARGS" ]]; then DW_ARGS+=("$DW_EXTRA_CMDLINEARGS"); fi # Wait until GPSD is running: -while ! pgrep gpsd >/dev/null 2>&1; do - sleep 1 -done +if ! chk_disabled "$DW_WAIT_GPSD"; then + while ! pgrep gpsd >/dev/null 2>&1; do + sleep 1 + done +fi # Wait until GPSD is established sleep 10