用sed插入字符串


-1

我需要使用以下帮助来查找和插入字符串sed

之前:

"AdminHostName" value=""

后:

"AdminHostName" value="my-text"

Answers:


3

如果您只想替换为空value

sed 's/value=""/value="my-text"/'

通过对问题的模糊描述,以下内容也适用:

sed 's/""/"my-text"/'
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.