Quick one-off here, let’s begin.
Git has nice colored diffs, like this:
Perforce does not:
A simple script can remedy this:
Here’s the script:
Simply drop it somewhere in your $PATH and use it like so:
p4 diff | p4c.rb
You can find it in my one-offs directory (it’s called p4c.rb). We recently switched from subversion to perforce (definitely not my choice, I pushed for git), and so far it’s awful. I am definitely not a fan. This makes it a little better.