-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to recognise Dockerfiles with extensions #4566
Comments
This issue has been automatically marked as stale because it has not had activity in a long time. If this issue is still relevant and should remain open, please reply with a short explanation (e.g. "I have checked the code and this issue is still relevant because ___."). Thank you for your contributions. |
This is only a smaller part of a larger underlying issue — Linguist has no way of identifying files based upon a common prefix, only a suffix (file extension) or complete filename. Dockerfiles aren't the only thing affected by this; many Makefiles have suffixes that match their relevant architecture; e.g., |
Ditto |
This issue has been automatically marked as stale because it has not had activity in a long time. If this issue is still relevant and should remain open, please reply with a short explanation (e.g. "I have checked the code and this issue is still relevant because ___."). Thank you for your contributions. |
Still relevant. See https://twitter.com/brunoborges/status/1175107507909320704 for example. |
Adding my vote for this one, as it impacts Jenkins, Docker, Makefile, and probably several others. If adding a more general regexp matching is complicated, we could probably get a lot of value out of simple prefix matching in the same way we do extension matching - e.g. for Groovy it might look like this:
|
I've tentatively started work on this in the |
Preliminary Steps
Please confirm you have...
Problem Description
We can name a dockerfile multiple ways. Usual way is to name it as it is either
Dockerfile
ordockerfile
in this case GitHub recognizes a dockerfile. But it's a usual practice that developers name them with extensions likeDockerfile.dev
orDockerfile.prod
or similar to it. In these case GitHub fails to recognize them as Dockerfiles.URL of the affected repository:
All repos using Dockerfiles with extensions.
examples:
https://github.com/kmehant/foundation.mozilla.org/blob/master/dockerfiles/Dockerfile.node
Last modified on:
Expected language:
Dockerfile
Detected language:
nothing
The text was updated successfully, but these errors were encountered: