bash: visual btrfs filesystem df oneliner


SUBMITTED BY: Guest

DATE: April 2, 2013, 8:39 a.m.

FORMAT: Bash

SIZE: 276 Bytes

HITS: 1401

  1. RATIO=`btrfs filesystem df / | grep Data | cut -d':' -f2 | sed -r 's/\w+=| |\.[0-9][0-9]GB//g' | sed -r 's|([0-9]+),([0-9]+)|\2/\1|'`; clear; for i in `seq 1 $((100*$RATIO))`; do echo -n '#'; done; for i in `seq 1 $((100-100*$RATIO))`; do echo -n '-'; done; echo

comments powered by Disqus