Browse Source

chg: [vps] improve raw formatting of ``stats`` action

pull/4/head
Valentin Lab 1 year ago
parent
commit
cccb7f8341
  1. 8
      bin/vps

8
bin/vps

@ -2142,8 +2142,12 @@ cmdline.spec::cmd:stats:run() {
:state-dir:
for resource in "${resources[@]}"; do
[ "$opt_format" == "pretty" ] && echo "${WHITE}$resource${NORMAL}:"
stats:"$resource" "$opt_format" 2>&1 | prefix " "
if [ "$opt_format" == "pretty" ]; then
echo "${WHITE}$resource${NORMAL}:"
stats:"$resource" "$opt_format" 2>&1 | prefix " "
else
stats:"$resource" "$opt_format" 2>&1 | prefix "$resource "
fi
set_errlvl "${PIPESTATUS[0]}" || return 1
done
}

Loading…
Cancel
Save