Macchina-CLI / libmacchina

A library providing access to all sorts of system information.
https://crates.io/crates/libmacchina
MIT License
66 stars 20 forks source link

OperatingSystem implementation for Linux #167

Open be4zad opened 5 months ago

be4zad commented 5 months ago

It seems operating system name is same with distro name. Isn't it better to remove GeneralReadout::distribution() and replace it by GeneralReadout::os_name()?

be4zad commented 5 months ago
behzad@arch ~> hostnamectl
Operating System: Arch Linux 
…
grtcdr commented 5 months ago

I made that distinction in the API to accommodate the differences in semantics between operating systems. Operating systems built on Linux refer to themselves as distributions and the API reflects that, whether that was the right choice is debatable. I just don't think it's worth breaking backwards-compatibility for such a minor problem.