#Bash 的 builtin 命令
builtin [CMD [ARG]...]
功能
绕过命令查找,执行一个内置命令。
Bash 查找命令的顺序为
别名 > 函数 > 内置命令 > 可执行文件;此命令跳过查找过程,直接执行内置命令。
类型
Bash 内置命令。
参数
CMD- 要执行的内置命令ARG- 命令的参数列表
#相关命令
| 命令 | 说明 |
|---|---|
| command | 忽略别名和函数,执行命令 |
命令前加
\前缀可以忽略别名,执行命令。
#推荐阅读
#手册
builtin: builtin [shell-builtin [arg ...]]
Execute shell builtins.
Execute SHELL-BUILTIN with arguments ARGs without performing command
lookup. This is useful when you wish to reimplement a shell builtin
as a shell function, but need to execute the builtin within the function.
Exit Status:
Returns the exit status of SHELL-BUILTIN, or false if SHELL-BUILTIN is
not a shell builtin.