From: Steven Baltakatei Sandoval Date: Tue, 23 May 2023 01:39:57 +0000 (+0000) Subject: fix(user/bkdatev):Make compatible with Bash 3.2.57 X-Git-Tag: 0.8.2^2~7 X-Git-Url: https://zdv2.bktei.com/gitweb/BK-2020-03.git/commitdiff_plain/be603b6fc18aaa59a35f668bc5eccd18b1ce41a0?hp=be603b6fc18aaa59a35f668bc5eccd18b1ce41a0 fix(user/bkdatev):Make compatible with Bash 3.2.57 - Note: In Bash 5.1, a negative length argument in a parameter substitution (i.e. the `$len` in `${myVar:$start_idx:$len}`) causes the last characters of the $myVar string to be truncated which is convenient in various applications. However, a negative length in Bash 3.2.57 (a macOS machine I happen to have) throws an error; for compatibility, I've instead added an additional arithemetical operation to calculate the positive length that corresponds to a truncation by 2 of the total string length. ---