hardlinks="${y#$initial_space}" # remove any initial spaces
hardlinks="${hardlinks%%[[:space:]]*}" # remove everything beyond first word
# ignore the hardlinks that files/dirs always have
- if [[ ${line:0:1} == d ]]; then
- hardlinks=$(( hardlinks - 2 ))
- else
- hardlinks=$(( hardlinks - 1 ))
- fi
- [[ $hardlinks == 0 ]] && hardlinks=
+ hardlinks=$(( hardlinks - 1 ))
+ [[ $hardlinks == 0 ]] && hardlinks=
if (( ${#hardlinks} > max_hl_digits )); then
max_hl_digits=${#hardlinks}
fi