g
[!
]/
pattern/
[commands]Execute commands on all lines which contain pattern or, if address is specified, on all lines within that range. If commands are not specified, print all such lines. Add a !
to execute commands on all lines not containing pattern. See also v.
:g/Unix/p :g/Name:/s/tom/Tom/