-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Closed
Labels
Description
reported here: https://bugs.launchpad.net/ubuntu/+source/rust-coreutils/+bug/2112445
#!/bin/sh
list='alpha avr hppa m68k loongarch64 (loong64) microblaze microblazeel or1k rx sh4 sh4eb tricore xtensa xtensaeb'; \
echo $list; \
len2=$((${#list}/2)); echo len2 = $len2; \
len2=$((${#list}/2)); \
if [ $len2 -gt 36 ]; then \
while expr substr "$list" $len2 1 != " " >/dev/null; do \
len2=$(($len2+1)); \
echo $len2; \
done; \
list="$(expr substr "$list" 1 $(($len2-1)))\${Newline} $(expr substr "$list" $(($len2+1)) $len2)"; \
fi;
currently displays:
alpha avr hppa m68k loongarch64 (loong64) microblaze microblazeel or1k rx sh4 sh4eb tricore xtensa xtensaeb
len2 = 53
54
55
56
57
[...]
It should display
alpha avr hppa m68k loongarch64 (loong64) microblaze microblazeel or1k rx sh4 sh4eb tricore xtensa xtensaeb
len2 = 53