#linux #filesystem #fs

lfs-core

give information on mounted disks

24 releases

0.11.1 Dec 10, 2022
0.11.0 Mar 4, 2022
0.10.2 Mar 2, 2022
0.7.0 Dec 30, 2021
0.3.1 Oct 18, 2020

#393 in Filesystem

Download history 473/week @ 2023-02-05 393/week @ 2023-02-12 640/week @ 2023-02-19 428/week @ 2023-02-26 440/week @ 2023-03-05 974/week @ 2023-03-12 678/week @ 2023-03-19 677/week @ 2023-03-26 476/week @ 2023-04-02 616/week @ 2023-04-09 1648/week @ 2023-04-16 384/week @ 2023-04-23 1300/week @ 2023-04-30 1332/week @ 2023-05-07 485/week @ 2023-05-14 510/week @ 2023-05-21

3,657 downloads per month
Used in 2 crates

MIT license

24KB
571 lines

MIT Latest Version docs Chat on Miaou

Give information on the mounted disks.

lfs-core provides the data of lfs and of the :fs screen of broot.


lib.rs:

Use lfs_core::read_mounts to get information on all mounted volumes on a unix system.

// get all mount points
let options = lfs_core::ReadOptions::default();
let mut mounts = lfs_core::read_mounts(&options).unwrap();
// only keep the one with size stats
mounts.retain(|m| m.stats.is_ok());
// print them
for mount in mounts {
dbg!(mount);
}

The lfs application is a viewer for lfs-core and shows you the information you're expected to find in mounts.

Dependencies

~2–2.8MB
~72K SLoC