Oh yes, I have successfully done this on IntelliJ (free Community Edition).
Menu > Analyze > Inspect Code…
In the result, select “Java language level migration aids > Explicity type can be replaced with <>”
Right click, run “Apply Fix ‘Replace with <>'” And you got diamonds.
There was a bug about diamond on anomymous classes, so some code may not compile after the fix. You’ll have to revert them back then.
// anonymous class, <> doesn't work.
new Factory<Pig>(){ ... }
// however IntelliJ may wrongly "fix" it to
new Factory<>(){ ... } // does not compile.