There is so much superfluous cruft in the message.
Listing the error, and the fix, would give exactly as much context for the next person to run into this issue.
If your goal to explain the process to find similar cases, just a couple more lines would have done just as well:
-
Fixes case where `bundle exec rake` would fail with error message:
ArgumentError: invalid byte sequence in US-ASCII
This is caused by the presence of non-ASCII characters in files.
The following command was used to find files with non-ASCII characters:
`find modules -type f -exec file --mime {} \+ | grep utf`
Running `iconv -f UTF8 -t US-ASCII` on listed files will show the exact location of offending characters.
-
No long winded exposition, no extremely case specific program output (including current machine's name...)
I’m not saying this is the worst commit message ever, and I’d appreciate the intention if I came across it, but if you’re caring enough to give this much context, you can save both yourself, and the next person to look for your message, some cognitive load by sticking to what’s needed.
-
And if you’re wondering how to decide “what is needed”, it varies, but I think a good rule of thumb is: ask yourself how one would find this commit message
What would someone grep for in git's history if they came across this? And if they found it, what information answers their query?
They’re likely to search the command that is failing, and the error.
The answer to that query is, what causes the command to error out, and how to find cases of that cause.
They’re not going to search for the program output of find, or iconv, not going to search for the exact file you were modifying when this happened, or the fixes you tried that didn’t work.