On 26.04.2021 21:28, Peter Oliver wrote:
Two patches are attached to address this:
- The first patch adds a new choice to ruby-insert-encoding-magic-comment,
unless-utf8, which causes the magic comment not to be inserted if the
encoding is UTF-8.
- The second patch, perhaps more controversially, makes this the default.
Both changes make sense to me.
However, I've looked at the existing code and found a prior change which
intended for this to be more customizable already, yet had a minor bug.
Please try out the following patch: