-
Notifications
You must be signed in to change notification settings - Fork 9
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
Bash driver is not a detected language #39
Comments
As @mcuadros said, we could also modify enry. Alternatively, we could support more than one language name per driver in the manifest which is probably more future-proof (example: python2+python3, typescript+javascript, etc). |
cc @mcuadros what should we do about this? I don't think enry (or github/linguist) is ever going to be able to tell bash apart other shell dialects in a reliable way. Should we just document this and recommend users to use |
I like this idea as it simplifies things for clients as they can just call bblfsh with output of enry |
Small summary of the context for this issue below. Use case
Problem
Alternatives
It may be a good time to implement any of this directly in v2, when we decide to port WDYT about approach 3? Feedback is very welcome. |
My proposal (make the languages field a list or a string with a separator) doesn't imply generating multiple drivers, just multiple names for the same drivers. |
I'm not familiar with the codebase very much, but a quick glance showed that in this case, on top of the mandatory changes listed in 3, we would also need to
Would not that be the case? If you could give some preliminary pointers to which parts of the codebase would be touched by such proposal, that would be very appreciated! |
Yes, changes are going to be needed in any case. We could also keep the same language field and all a "language_aliases" field (instead of "enry_languages" so we're not tying the drivers to enry in any way). |
I would rather use something like |
@juanjux @smola Having a separate field have benefits that at least we do not need to touch any templates/driver generation part. So far, the only changes that I found to be needed in this case seem to be well localized and are listed in 3. (And we even seem to have an option of not changing a protocol1 at all! I vote for that.) If there is no more feedback, I will be moving result of this discussion with a proposal to a separate issue in SDK in next few days, as it's not Bash specific at all. We can keep this one open until that one is merged and released. |
I'm fine with the new field then, too. |
Signed-off-by: Denys Smirnov <denys@sourced.tech>
Signed-off-by: Denys Smirnov <denys@sourced.tech>
We use enry for language detection both on bblfshd side as well as on our applications. Enry, as well as github/linguist, do not detect Bash itself, but just Shell (this includes the whole family of POSIX-like shell languages).
This generates the following problem:
The text was updated successfully, but these errors were encountered: