davidjamesweir’s avatardavidjamesweir’s Twitter Archive—№ 1,014

    1. Took some time, but finally: if you want to recolour git diff or wdiff -3 output: sed "s/\[-/echo -e \"\x1b\"[91m[-/g; \ s/-\]/echo -e \-]"\x1b\"[0m/g; \ s/{+/echo -e \"\x1b\"[92m{+/g; \ s/+}/echo -e \+}"\x1b\"[0m/g;"
  1. …in reply to @davidjamesweir
    I'm diffing two latex source files, and the old one was committed with CR rather than CRLF, so I wanted to strip them out from the git diff --word-diff output, but keep the colouring.