Re:Whistleblower: Ubiquiti Breach “Catastrophic”
by colineartheta on Tuesday March 30, 2021 @04:58PM
(#26640391)
Just curious (I agree with you), but what are the s/ and /g for? Samsung and Google?
[ Parent
| on HN ]
Re:Whistleblower: Ubiquiti Breach “Catastrophic”
by brod on Tuesday March 30, 2021 @05:05PM
(#26640495)
I think the OP is using the sed syntax [0] to say:
> Now rewrite your entire comment with sonos instead of ubiquiti.
Re:Whistleblower: Ubiquiti Breach “Catastrophic”
by actimia on Tuesday March 30, 2021 @05:07PM
(#26640533)
It is a `sed` command, used to replace (s/) all (/g) instances of the first word with the second.
Re:Whistleblower: Ubiquiti Breach “Catastrophic”
by inetknght on Tuesday March 30, 2021 @05:05PM
(#26640511)
Good tools support search and replace. Better tools support regular expressions.
Re:Whistleblower: Ubiquiti Breach “Catastrophic”
by tinco on Tuesday March 30, 2021 @05:07PM
(#26640527)
It's how you do a text replacement in VIM, I believe it's s for substitute, /../ for the regular expression, and g for global, to substitute multiple instances.
Re:Whistleblower: Ubiquiti Breach “Catastrophic”
by roland35 on Wednesday March 31, 2021 @08:15AM
(#26646210)
Don't forget the % if you are using vim, to make sure you replace on all lines :)
:%s/ubiquity/sonos/g
Re:Whistleblower: Ubiquiti Breach “Catastrophic”
by istjohn on Tuesday March 30, 2021 @05:05PM
(#26640502)
That's the syntax for search on replace with sed on Linux.
Re:Whistleblower: Ubiquiti Breach “Catastrophic”
by vishnugupta on Wednesday March 31, 2021 @03:08AM
(#26644325)
“/s” stands for search and “/g” for “global” replace.