Last Updated: 2022-12-01
At some point in Ruby history, the normal way of writing hashes went from
=> value to
key: :value. I was maintaining a legacy application and decided
at the time to write all future hashes in the new format but leave existing ones
intact (to save effort).
But years down the lane, this turned out to be a bad idea. Why? Because it became more difficult to do searches and replaces across the entire (now much larger) project, since I had to consider both cases in my regexes.
Also noisy future commits were created where a future linter fixed the remaining entities piecemeal as that file was edited.
If you're going to change syntax style, change everything at once.