Skip to content

Commit

Permalink
- show size of NFS if available
Browse files Browse the repository at this point in the history
  • Loading branch information
aschnell committed May 27, 2024
1 parent b3d4dab commit cf159ff
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions barrel/show-filesystems.cc
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
#include <storage/Filesystems/Nfs.h>
#include <storage/Storage.h>
#include <storage/Environment.h>
#include <storage/FreeInfo.h>

#include "Utils/GetOpts.h"
#include "Utils/Table.h"
Expand Down Expand Up @@ -182,6 +183,12 @@ namespace barrel
{
const Nfs* nfs = to_nfs(filesystem);
row[Id::NAME] = nfs->get_server() + ":" + nfs->get_path();

if (filesystem->has_space_info())
{
SpaceInfo space_info = nfs->detect_space_info();
row[Id::SIZE] = format_size(space_info.size);
}
}

if (filesystem->has_mount_point())
Expand Down

0 comments on commit cf159ff

Please sign in to comment.