[PATCH] Options to set fixed unit for `filesystem df`

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Currently, `btrfs filesystem df` uses the pretty_size() function, which
automatically selects a unit to display a size in, e.g. 1024 bytes will be
displayed as "1.00KiB".
This makes parsing the output of `filesystem df` unnecessarily hard, so I've
added the options -b, -k, -m, and -g to get the output in bytes, kibi-, mebi-,
and gibibytes respectively.

Nils Steinger (1):
  Add options to use a fixed unit for `filesystem df` instead of
    determining it automatically.

 cmds-filesystem.c | 62 ++++++++++++++++++++++++++++++++++++++++++++++++-------
 utils.c           | 30 +++++++++++++++++++++++++++
 utils.h           |  8 +++++++
 3 files changed, 93 insertions(+), 7 deletions(-)

-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Filesystem Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux