Cheat is a python-based command reminder tool. Compared to lengthy and vague man and info pages, cheat provides distinct instructions to the options, arguments, or common uses of common commands. With cheat, system administrators can also edit existing cheat sheets or create custom cheat sheets for any subjects.
Cheat can be installed on all kinds of Unix-like systems. In this article, I will only demonstrate the steps on a CentOS server instance.
Before moving on, you need to:
The easiest way to install cheat is with pip:
sudo yum update sudo yum install -y python-devel python-setuptools python-pip sudo pip install --upgrade pip sudo pip install cheat
Edit the current user's
.bashrc file to specify the default editor for editing cheat sheets, and to enable syntax highlighting:
Add the following two lines beneath the line "fi":
export EDITOR=/usr/bin/vim export CHEATCOLORS=true
Save and quit:
Put the changes into effect:
To view a cheat sheet:
[xyz] is the name of the command that you want to query.
To search a cheat sheet including your input
cheat -s [xyz]
All of the related contents in cheat sheets that include the phrase
[xyz] will be displayed on the screen.
To list all of the available cheat sheets:
To edit an existing cheat sheet or to create a custom cheat sheet:
cheat -e [xyz]
To see the version of cheat program:
To see the store locations of cheat sheets: