举个伪造的例子:

python main.py /home/user/aaa/bbb/ccc/ddd/eee/test.mp4 /data/user/project/test/tmp/admin/20180720/data-center/whatever/tmp.pkl --Port=10000 /data/user/project/test/tmp/admin/20181122/data-center/save-results/ -b 16 -p 0.1

我发现其中有个参数--Port写错了,应该写成--port,我可以通过Alt-b往回跳修改,但是是以单词来跳的,如果命令太长跳起来也比较费时间,想问下没有类似搜索P的命令,直接调到P所在位置


$ man bash

...

edit-and-execute-command (C-xC-e)

Invoke an editor on the current command line, and execute the result as shell commands. Bash attempts to invoke $VISUAL, $EDITOR, and emacs as the editor, in

that order.

...

即 ctrl-x ctrl-e 调用 $EDITOR 来编辑命令保存然后运行。会用$EDITOR就随便搜索,修改了。


先按 &, 然后按 Ctrl-],再按 P


谢邀。

我只熟悉vi的操作方法。

1 打开终端时,在终端中输入set -o vi,将输入模式切换为vi;

2 正常输入待处理命令;

2 按下esc键,输入FP,即可跳到Port中的P;

3 按下s键,输入p,完成替换


terminal里也好像有个像vim操作的插件,不知道有没有卵用,没怎么用过,像楼主提到的像emacs中的goto-char的功能就不知道了


linux里有一个神器命令是fuck,专门用于纠正输入的错误命令。


你是要干嘛 搜索指令或者文件吗


推荐阅读:
相关文章