Linux 中的 sed b 命令是什么? [英] What is sed b command in Linux?
本文介绍了Linux 中的 sed b 命令是什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我只是想知道 Linux 中 sed
的 b
命令是什么.例如:
I am just wondering what is the b
command for sed
in Linux. For example:
sed "/some pattern/b" a.txt
推荐答案
b
命令 代表分支:无条件分支到标签.可以省略标签(如您的示例),在这种情况下,下一个循环开始.
The b
command stands for branching: unconditionally branch to label. The label may be omitted (as in your example), in which case the next cycle is started.
请注意,在大多数情况下,使用此命令意味着您最好使用一些真正的编程语言(例如 awk、Perl 或 Python)进行编程.
Note that in most cases, use of this command means that you are probably better off programming in some real programming language like awk, Perl or Python.
这篇关于Linux 中的 sed b 命令是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文