What\'s your preferred way of getting current system status (current CPU, RAM, free disk space, etc.) in Python? Bonus points for *nix and Windows platforms.
There s
Only for Linux: One-liner for the RAM usage with only stdlib dependency:
import os tot_m, used_m, free_m = map(int, os.popen('free -t -m').readlines()[-1].split()[1:])
edit: specified solution OS dependency