Refer: https://gist.github.com/stefanocudini/4704616 If you are using a file like crontab.txt egrep -rv '^\s*[#;]|^\s*$' crontab.txt | perl -ane 'print join("\t", @F[0..5], join(" ", @F[6..$#F])),"\n" unless /MAILTO/' | sort -nt$'\t' -k2 -k1 | column -t -s$'\t' > crontab-out.txt Or from crontab itself, if you have access egrep -rv '^\s*[#;]|^\s*$' /etc/cron.d/* | perl -ane 'print join("\t", @F[0..5], join(" ", @F[6..$#F])),"\n" unless /MAILTO/' | sort -nt$'\t' -k2 -k1 | column -t -s$'\t'