Hacker News new | ask | show | jobs
by skywhopper 4480 days ago
The rant linked to appears to misunderstand the problem and the workaround. @arfon admits there's what amounts to a design bug in Linguist, and so to identify ".m" files, you have to identify a different extension as the "primary" and put the real extension into the "alternate" list. That's a hacky workaround, but it would make the pull request work.

The alternative is to fix the design issue. But that's going to be a lot harder and require more than a few days.

1 comments

@arfon doesn't admit that there's a bug, rather he says that "requiring a unique primary_extension isn't really a 'bug', rather it's a consequence of how language detection works in Linguist."

The work to fix the design issue was already done by @nox, who submitted a pull request which is still open: https://github.com/github/linguist/pull/985

I guess the charitable reading is "this isn't a bug, it's more of a bad design choice, and we can't just fix it overnight".

But I honestly can't tell if that's what he meant, or if it was more of a "not my problem" type of response.

Except that it was totally fixed overnight. No, wait. Not overnight. Over two hours.

Of course that PR isn't being accepted either.