繁体   English   中英

通过 shell 行代码执行正确的 inputrc 命令

[英]Do the correct inputrc command by a shell line code

我们如何通过 shell 行代码执行 inputrc 命令,因为这里给出了失败

$ bind -x '"\C-l":next-history'

bash: next-history: command not found  
$ 

请做真诚的帮助

根据man bash

  • -x keyseq : shell 命令

    每当输入keyeq时,都会执行shell-command [...]

因此,对于您的情况,当您按下CTRL-L时,Bash 将尝试执行名为next-history的命令。

到 map 到 Readline 的next-history ,你可以这样写:

bind '"\C-l": next-history'

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM