Some improvements to statfs.py and added terminal formatting handler