Daniel Shahaf wrote on Tue, Jul 30, 2013 at 17:46:44 +0300: > Stefan Fuhrmann wrote on Tue, Jul 30, 2013 at 16:30:00 +0200: > > Well, I got kind of fed up after manually patching > > ~180 files (about the same number of files left to > > check). Even the commit took longer than 4 minutes. > > > > So, feel free to do some search/replace magic to > > handle the remaining files. > > What makes you think I'm not as lazy as you are? :-)
Just re-read what you wrote... *manually* patching 180 files? I'd never have had the patience to do 180 files by hand. I'd have been happy to whip up a one-off script to fix them in batch... Pseudocode: grep -n '(?P<m>"svn_hash.h")\|(?P<n>"svn_private_config.h")' if m and n and m<n vim \ -c "$n d" \ -c '-,.!uniq' \ # deduplicate empty lines -c "$m normal\! {O#include \"svn_private_config.h\"" -c o \ -c wq