Skip to content

Commit

Permalink
shellcheck
Browse files Browse the repository at this point in the history
  • Loading branch information
mtekman committed Nov 1, 2022
1 parent 6c1efdd commit b93b18a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions dietpi/func/dietpi-banner
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@
## Sometimes the title is long, so a sanity check is performed to fold the title
## if it exceeds the window size. Because of the hyphen it receives 3 spaces padding.
if (( $title_len >= $TERM_WIDTH )); then
title=$(echo "$stripped_title" | fold -s -w $TERM_WIDTH)
title=$(echo "$stripped_title" | fold -s -w "$TERM_WIDTH")
title="${title//$'\n'/$'\n' }"
title="${aCOLOUR[1]}${title}$COLOUR_RESET"
## Recalculate the title length based on the last line with padding
Expand All @@ -132,7 +132,7 @@
## The description is typically very long, and is folded from the second line
## onwards into the remaining available space, with left padding.
if (( $descp_len >= $avail_len )); then
descp=$(echo "$stripped_descp" | fold -s -w $avail_len)
descp=$(echo "$stripped_descp" | fold -s -w "$avail_len")
descp="${descp//$'\n'/$'\n'${left_pad}}"
fi
fi
Expand Down

0 comments on commit b93b18a

Please sign in to comment.