你的浏览器版本过低,可能导致网站不能正常访问!
为了你能正常使用网站功能,请使用这些浏览器。

给大家推荐一款学习神器 — kmdr,让你解锁 Linux 学习新姿势

[复制链接]
gaosmile 发布时间:2020-3-6 14:28
大家都知道,Linux 系统有非常多的命令,而且每个命令又有非常多的用法,想要全部记住所有命令的所有用法,恐怕是一件不可能完成的任务。


一般情况下,我们学习一个命令时,要么直接百度去搜索它的用法,要么就直接用 man 命令去查看守冗长的帮助手册。这两个都可以实现我们的目标,但有没有更简便的方式呢?


答案是必须有的!今天给大家推荐一款有趣而实用学习神器 — kmdr,让你解锁 Linux 学习新姿势。


kmdr 工具最大的亮点就是,如果有一个长串命令你看不懂它的用法及意义,它将直接分模块给你详细解释!这个功能真的是非常实用,因为我们在网上或书上难免会看到各种各样的命令,如果你看不懂,那将永远留下疑惑。而这个工具就像老师一样,按模块一个个告诉你命令各个部分的用法及意义,让你一目了然!


kmdr 收纳了非常多的 CLI 命令解释,例如常见的 ansible, conda, docker, git, go, kubectl, mongo, mysql, npm, ruby gems, vagrant 等等,不仅如此,那些 bash 内置命令 它都能为你解释,非常给力!


不管你是哪个领域的程序员,kmdr 都能最大限度地为你提供 CLI 命令学习帮助。


Bash Shell 命令(如 echo,export,cd)
容器(如 Docker,kubectl)
版本控制(如 Git)
数据库服务器和客户端(如 mysql,mongod)
部署/云(如 now cloud)
文件和存档工具(如 zip,tar)
媒体(如 ffmpeg,youtube-dl)
网络/通讯(如 netstat,nmap,curl)
包管理器(如 dpkg,pip)
编程语言/运行时环境/编译器(如 go,python,node,gcc)
系统管理 /监控(如 crontab,top)
文字处理(如 awk,sed)
文本编辑器(如 nano,vim)
其他(如 openssl,bash,bash64)
这个链接里可以查看完整的支持列表:http://github.com/ediardo/kmdr-cli#supported-programs)






安装 Kmdr CLI






kmdr 是用 Nodejs 编写的免费开源工具,需要 Nodejs 版本 8.x 或更高版本才能运行,需要大家先准备好运行环境。


安装好 Nodejs 之后,使用 Npm 软件包管理器安装  kmdr:


$ npm install kmdr@latest --global
不想安装 Nodejs 这么麻烦?没关系,这里有一个网站可以让你在 web 浏览器直接使用 kmdr ↓↓  
http://demo.kmdr.sh/






使用 Kmdr 在终端中显示 CLI 命令说明






下面我们通过一条复杂点的命令作为例子,来看看 kmdr 究竟有多强!


$ history | awk '{print $2}' | sort | uniq -c | sort -nr | head -5
首先,运行下面的命令,让 kmdr 进入解释状态:


$ kmdr explain
接着,输入我们上面的示例命令,然后按 ENTER 键:


? Enter your command: history | awk '{print $2}' | sort | uniq -c | sort -nr | head -5


history
With no options, display the command history list with line numbers.
|
A pipe serves the sdout of the previous command as input (stdin) to the next one
awk
pattern scanning and processing language
{print $2}
An argument
|
A pipe serves the sdout of the previous command as input (stdin) to the next one
sort
Sort lines of text files
|
A pipe serves the sdout of the previous command as input (stdin) to the next one
uniq
Report or omit repeated lines
-c, --count
Prefix lines by the number of occurrences
|
A pipe serves the sdout of the previous command as input (stdin) to the next one
sort
Sort lines of text files
-n, --numeric-sort
Compare according to string numerical value
-r, --reverse
Reverse the result of comparisons
|
A pipe serves the sdout of the previous command as input (stdin) to the next one
head
Output the first part of files
-5
An argument


收藏 评论0 发布时间:2020-3-6 14:28

举报

0个回答

所属标签

STM32团队

意法半导体微控制器和微处理器拥有广泛的产品线,包含低成本的8位单片机和基于ARM® Cortex®-M0、M0+、M3、M4、M33、M7及A7内核并具备丰富外设选择的32位微控制器及微处理器


最新内容

关于
我们是谁
投资者关系
意法半导体可持续发展举措
创新与技术
意法半导体官网
联系我们
联系ST分支机构
寻找销售人员和分销渠道
社区
媒体中心
活动与培训
隐私策略
隐私策略
Cookies管理
行使您的权利
官方最新发布
STM32N6 AI生态系统
STM32MCU,MPU高性能GUI
ST ACEPACK电源模块
意法半导体生物传感器
STM32Cube扩展软件包
关注我们
st-img 微信公众号
st-img 手机版