I have a substitute expression to find words beginning with a dollar signs and capture them like this:
:%s/\$\(.*\)\>//g
However there are a lot of escape sequences in the regular expression (4). Is there a way to avoid so many escapes in this expression?
:%s/$\k\+//g
. 29% shorter! – Peter Rincker Feb 20 '18 at 16:34