#linux #fs

lfs-core

give information on mounted disks

26 releases

0.12.0 Dec 21, 2024
0.11.2 Oct 14, 2023
0.11.1 Dec 10, 2022
0.11.0 Mar 4, 2022
0.3.1 Oct 18, 2020

#80 in #fs

Download history 529/week @ 2024-10-27 557/week @ 2024-11-03 610/week @ 2024-11-10 458/week @ 2024-11-17 369/week @ 2024-11-24 453/week @ 2024-12-01 403/week @ 2024-12-08 528/week @ 2024-12-15 629/week @ 2024-12-22 609/week @ 2024-12-29 527/week @ 2025-01-05 561/week @ 2025-01-12 758/week @ 2025-01-19 1432/week @ 2025-01-26 1042/week @ 2025-02-02 586/week @ 2025-02-09

3,875 downloads per month
Used in 8 crates (4 directly)

MIT license

25KB
593 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

~3.5–5MB
~97K SLoC