mirror of
https://github.com/fofolee/uTools-Manuals.git
synced 2025-06-09 07:24:04 +08:00
38 lines
1.7 KiB
HTML
38 lines
1.7 KiB
HTML
<h1 id="bind">bind</h1>
|
||
<p>显示或设置键盘按键与其相关的功能</p>
|
||
<h2 id="补充说明">补充说明</h2>
|
||
<p><strong>bind命令</strong> 用于显示和设置命令行的键盘序列绑定功能。通过这一命令,可以提高命令行中操作效率。您可以利用bind命令了解有哪些按键组合与其功能,也可以自行指定要用哪些按键组合。</p>
|
||
<h3 id="语法">语法</h3>
|
||
<pre><code class="language-bash">bind(选项)</code></pre>
|
||
<h3 id="选项">选项</h3>
|
||
<pre><code class="language-bash">-d:显示按键配置的内容;
|
||
-f<按键配置文件>:载入指定的按键配置文件;
|
||
-l:列出所有的功能;
|
||
-m<按键配置>:指定按键配置;
|
||
-q<功能>:显示指定功能的按键;
|
||
-v:列出目前的按键配置与其功能。</code></pre>
|
||
<h3 id="实例">实例</h3>
|
||
<pre><code class="language-bash">bind -x '"\C-l":ls -l' #直接按 CTRL+L 就列出目录</code></pre>
|
||
<p>其中keyseq可以使用<code>showkey -a</code>命令来获取:</p>
|
||
<pre><code class="language-bash">[root@localhost ~]# showkey -a
|
||
|
||
Press any keys - Ctrl-D will terminate this program
|
||
|
||
^[[A 27 0033 0x1b 上
|
||
91 0133 0x5b
|
||
65 0101 0x41
|
||
^[[B 27 0033 0x1b 下
|
||
91 0133 0x5b
|
||
66 0102 0x42
|
||
^[[D 27 0033 0x1b 左
|
||
91 0133 0x5b
|
||
68 0104 0x44
|
||
^[[C 27 0033 0x1b 右
|
||
91 0133 0x5b
|
||
67 0103 0x43
|
||
32 0040 0x20
|
||
^M 13 0015 0x0d 字母M
|
||
^C 3 0003 0x03 Ctrl-C
|
||
^D 4 0004 0x04 Ctrl-D 退出</code></pre>
|
||
<!-- Linux命令行搜索引擎:https://jaywcjlove.github.io/linux-command/ -->
|