My question is rather simple, though I have had no luck finding an answer.
I\'d like to remove the leading plus/minus symbols from each line in git diff
git diff
One option is to use sed to remove the undesired character from diff, while preserving the color:
sed
git diff --color | sed -r "s/^([^-+ ]*)[-+ ]/\\1/" | less -r
(Note that you need to remove the leading space as well, as it is emitted by diff.)