一个文本文件,里面有如下内容
system:aaa
property:
length: 16
network:
property:
length: 32
这些行会在文件中出现很多次。我想把system:property:length 统一改成128,
其他的,比如network的都不要变,这个怎么用shell改?
file3是文本文件
sed ' /system/ {那两个‘N'是什么意思啊?这个length是system:property的一个属性,有的system中间可能会有其他属性,怎么办?比如
system:aaa
property:
duration:100
length: 16
我只想改所有system:property:length属性的值。
有点没有看明白:必须 system property length 在连续的三行上么?
还是 system开始的行,后面几行中的一个 length都可以修改
另外,system后是否肯定存在length 行