Linux获取帮助命令--man、help、info详细介绍分析

Linux中获取帮助的命令有很多,比如:man、help、info,但是各有不同!下面我们进行实践分析一下:

1.help

命令格式:

mv --help

显示效果:提供的是一种快捷、高效的帮助

mv: illegal option -- -
usage: mv [-f | -i | -n] [-v] source target
       mv [-f | -i | -n] [-v] source ... directory

2.man

命令格式:

man mv

显示效果:man页包含的某些GNU工具信息

MV(1)                     BSD General Commands Manual                    MV(1)

NAME
     mv -- move files

SYNOPSIS
     mv [-f | -i | -n] [-v] source target
     mv [-f | -i | -n] [-v] source ... directory

DESCRIPTION
     In its first form, the mv utility renames the file named by the source
     operand to the destination path named by the target operand.  This form
     is assumed when the last operand does not name an already existing direc-
     tory.

     In its second form, mv moves each file named by a source operand to a
     destination file in the existing directory named by the directory oper-
     and.  The destination path for each operand is the pathname produced by
     the concatenation of the last operand, a slash, and the final pathname
     component of the named file.

     The following options are available:
:

3.info

命令格式:

mv --help

显示效果:比man显示更完整的最新的GNU工具信息

File: *manpages*,  Node: mv,  Up: (dir)


MV(1)                     BSD General Commands Manual                    MV(1)

NAME
     mv -- move files

SYNOPSIS
     mv [-f | -i | -n] [-v] source target
     mv [-f | -i | -n] [-v] source ... directory

DESCRIPTION
     In its first form, the mv utility renames the file named by the source
     operand to the destination path named by the target operand.  This form
     is assumed when the last operand does not name an already existing direc-
     tory.

     In its second form, mv moves each file named by a source operand to a
     destination file in the existing directory named by the directory oper-
     and.  The destination path for each operand is the pathname produced by
     the concatenation of the last operand, a slash, and the final pathname
-----Info:(*manpages*)mv,83 行 --Top---------------------------------------


总结:

  • “–help”选项并不是一个“独立”的工具。作为一种命令的选项通常由一个或两个连字符后跟一个或多个字母来指定。选项出现在所调用的工具名后,用空格隔开。工具的其它参数都跟在选项后,也用空格隔开。

  • Man和info就像两个集合,它们有一个交集部分,但与man相比,info工具可显示更完整的最新的GNU工具信息。若man页包含的某个工具的概要信息在info中也有介绍,那么man页中会有“请参考info页更详细内容”的字样。
    通常情况下,man工具显示的非GNU工具的信息是唯一的,而info工具显示的非GNU工具的信息是man页内容的副本补充。

  • 1
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值