Linux CLI - Text Processing
You want to replace all occurrences of 'foo' with 'bar' only on lines containing 'baz' in
data.txt. Which command achieves this?data.txt. Which command achieves this?/baz/ s/foo/bar/g applies substitution only on lines matching 'baz'.15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions