I've recently made a little tool for myself (a very little tool) called 'cheat'. It is a command line tool which functions like a linux command line cheat sheet. Currently it consists of a .cheatrc file, containing a tab-separated table of handy commands and a description of what they do, and a script in /usr/bin which cats the file, greps for a search term and pipes to column for pretty printing. So whenever I come across a nifty bash command, i add it to my .cheatrc file and can find it easily later, with 'cheat <search term>'
For example suppose i want to find some info about my hard disk, if i run 'cheat disk', i get this;
dd bs=1M if=/dev/sda | gzip | ssh user@remote 'dd of=sda.gz' Backup harddisk to remote machine du -s * | sort -k1,1rn | head Show top disk users in current dir. See also dutop fdisk -l Show disks partitions sizes and types (run as root) smartctl -A /dev/sda | grep Power_On_Hours How long has this disk (system) been powered on in total hdparm -i /dev/sda Show info about disk sda hdparm -tT /dev/sda Do a read speed test on disk sda badblocks -s /dev/sda Test for unreadable blocks on disk sda
In future i want to add the ability to add cheats via the command line with 'cheat -a', 'cheat --add' or something.
The tool is almost ridiculously simple but i find i use it all the time, so my question is, do you think this project is worth developing into a full tool, releasing the source and trying to get it included in ubuntu releases? It certainly wouldn't waste much space on a live CD. Or has this been done already? Is there a better tool extant? Searching google for any combination of 'CLI' 'Cheat sheet' 'linux' and 'tool' only gives hundred of PDF linux cheat sheets, so i can't tell. What's your opinion?
[edit] The forum ignores tabs, so assume that the above output is all lined up in nice neat columns.