How do you use a macro to remove consecutive duplicate lines?
qayy:+1\nif getline('.')==@0|d|else|+1|endif\nq
Record a macro that yanks the current line and compares it with the next.
qayy:+1\nif getline('.')==@0|d|else|+1|endif\nq
Record a macro that yanks the current line and compares it with the next.
qa/^#\nddq
Record a macro that finds lines starting with # and deletes them.