CLI prints and sorts by attribute