小编rah*_*hul的帖子

单行匹配模式前后打印字段

我的文件包含以下数据:

tail fn0 logfile
more  tail3 fn0 logfile1
get than tail4 fn0 logfile2
Run Code Online (Sandbox Code Playgroud)

我想从 fn0 之前的字段和 fn0 之后的字段中获取输出。

预期输出:

tail logfile
tail3 logfile1
tail4 logfile2
Run Code Online (Sandbox Code Playgroud)

linux text-processing

2
推荐指数
1
解决办法
172
查看次数

标签 统计

linux ×1

text-processing ×1