Listing 20. Beginning sed scripts.
清单20.sed脚本。
Listing 2. Matched strings marked in sed.
清单2.sed中标记的匹配字符串。
Listing 20 shows three simple sed scripts.
清单20展示了三个简单的sed脚本。
Uncompressing sed into a temporary directory.
将sed解压缩到临时目录。
This will cause sed to delete any matching lines.
这将导致sed删除任何匹配的行。
There are ways to do this with grep, sed, and perl.
可以通过使用 grep、sed和 perl完成此工作。
Why not take some time to install GNU sed 3.02.80 now?
现在为什么不花些时间安装GNUsed 3.02.80呢?
A set of sed commands is usually called a sed script.
sed命令集常常被称为sed脚本。
Every Linux distribution has GNU sed, or at least should.
每一个Linux发行版都有(或至少应该有)GNUsed。
Start txt2regex and specify regexps for grep, sed, and emacs.
启动txt2regex并指定构建用于grep、sed和Emacs的regexp。
Using the editor sed to script complex changes to text files.
使用编辑器sed编写脚本,对文本文件做出复杂的修改。
You'll notice that sed performs its desired task with flying colors.
您将注意到,sed 成功完成了预期任务。
Sed is line-based, so the commands are performed on each line in order.
sed是基于行的,因此按顺序对每一行执行命令。
You can also alter text from the command line using patterns, replace, and sed.
还可以使用模式、替换和sed从命令行更改文本。
You can also do regexp highlighting in sed, the stream editor. The sed command.
还可以在sed(流编辑器,stream editor)中进行regexp突出显示。
This is simply a special keyword that tells sed to match either a TAB or a space.
这只是一个特殊的关键字,它告诉sed与TAB或空格匹配。
In addition to operating on individual lines, sed can operate on a range of lines.
除了操作单独的行外,sed还可以操作一个行范围。
You had used regexps for egrep, sed, and perl; now try building it for plain grep.
前面已经使用了适用于egrep、sed和perl的regexp,现在我们将尝试构建适用于普通grep的regexp。
The 'd' command didn't simply tell sed to delete all incoming data in one fell swoop.
d'命令不是简单地告诉sed 一下子删除所有输入数据。
There are many handy sed one-liners such as Listing 22. See Resources for links to some.
还有许多像清单22这样方便的sed单行脚本。参见参考资料获得其中一些脚本的链接。
By using addresses, you can tell sed to perform edits only on a particular line or lines.
通过使用地址,可以告诉sed只对某一或某些特定行进行编辑。
This article helps you better understand the regular expressions used by both grep and sed.
本文将帮助您更好地理解grep和sed使用的正则表达式。
Version 4 of sed contains documentation in info format and includes many excellent examples.
sed的第四版包含info格式的文档,并附带了许多出色的示例。
Some versions of sed have an -i option, which specifies that the input file should be edited.
某些版本的sed有一个-i选项,此选项指定应该编辑的输入文件。
And, sed writes its results to standard output (stdout); it doesn't modify any input files.
然后,sed将其结果写入标准输出(stdout),它不修改任何输入文件。
You don't have to sed, awk, grep, and perl your way through reams of onstat or snapshot data.
您不必对大量onstat或快照数据进行 sed、awk、grep和perl 操作。
This includes crafting loops and knowing how to parse data using utilities like awk, grep, and sed.
这包括巧妙使用循环和知道如何使用awk、grep和sed等的实用程序解析数据。
However, if you're new to sed, it's very important that you understand them. Here's our first example.
然而,如果您是sed新手,那么理解它们是十分重要的。
This small introduction should whet your appetite for sed, but is not intended to be complete or extensive.
下面的简单介绍将唤起您对sed的兴趣,但是这里并不打算给出全面或详细的介绍。
应用推荐