??繼 Linux 學(xué)習(xí)筆記 0 安裝 Linux 后開(kāi)始學(xué)習(xí) Linux 命令。首先學(xué)習(xí)的是獲得命令幫助,最常用的有 help,man,info 和基于 Python 的 cheat 。
-
help
??help 命令用于顯示內(nèi)嵌命令的相關(guān)信息,大多數(shù)外部命令也可以通過(guò) --help 選項(xiàng)獲得幫助信息。type 命令可以區(qū)分命令的類型。
type command
help command
command --help
help and type -
man
??Man(manual) 命令是 Linux 下的幫助指令,通過(guò) man 指令可以查看 Linux 中的指令幫助、配置文件幫助和編程幫助等信息。man 命令比 help 顯示更詳細(xì)的幫助信息。
man command
man -k keyword
man command -
info
??info 命令是 man 命令的詳細(xì)內(nèi)容。但 man 使用起來(lái)要方便的多。一個(gè) man 只有一頁(yè),而 info 總是將它們的內(nèi)容組織成多個(gè)區(qū)段(節(jié)點(diǎn)),每個(gè)區(qū)段也可能包含子區(qū)段(子節(jié)點(diǎn))。info 工具可顯示更完整的最新的 GNU 工具信息。通常 man 中若包含的信息概要在 info 中也有時(shí),會(huì)有提示:“請(qǐng)參考 info 頁(yè)更詳細(xì)內(nèi)容”。
info command
info command -
cheat
??cheat(cheatsheet) 是在GNU通用公共許可證下,為L(zhǎng)inux命令行用戶發(fā)行的交互式備忘單應(yīng)用程序。它提供顯示Linux命令使用案例,包括該命令所有的選項(xiàng)和簡(jiǎn)短但尚可理解的功能。cheat 依賴 Python 和 pip 。 Ubuntu Server 16.04 LTS
已默認(rèn)安裝 Python,包括 Python2 和 Python3,安裝 pip 后便可安裝 cheat 了。以下在 Python3 下安裝 pip 和 cheat 。
apt-get install python3-pip python-dev build-essential
pip install --upgrade pip
pip install --upgrade virtualenv
pip install cheat
安裝后可對(duì) cheat 進(jìn)行自動(dòng)補(bǔ)全,默認(rèn)編輯器等相關(guān)配置。
查看可用的速查表
參考
Uinx/Linux上的幫助查詢命令
Linux 命令之(1) 幫助命令之help
Linux獲得命令幫助(學(xué)習(xí)筆記五)
Cheat : 一個(gè)實(shí)用 Linux 命令示例集合
Cheat—— 給Linux初學(xué)者和管理員一個(gè)終極命令行"備忘單"
Linux常用命令



