vim how to append to every line code example
Example 1: vim how to append to every line
# Basic syntax:
:%s/$/text_to_add/g
Example 2: vim insert text before every line
:'<,'>s!^!//!
# Basic syntax:
:%s/$/text_to_add/g
:'<,'>s!^!//!