Add JsLIGO support
Description
Checklist:
- [x] I am adding a new language.
- [x] The extension of the new language is used in hundreds of repositories on GitHub.com.
- Search results for each extension:
- https://github.com/search?q=extension%3Ajsligo&type=code
- Search results for each extension:
- [x] I have included a real-world usage sample for all extensions added in this PR:
- Sample source(s):
- https://gitlab.com/ligolang/contract-catalogue/-/blob/main/lib/fa1.2/FA1.2.jsligo
- Sample license(s): MIT
- Sample source(s):
- [x] I have included a syntax highlighting grammar: [URL to grammar repo]
- [ ] I have updated the heuristics to distinguish my language from others using the same extension.
- [x] The extension of the new language is used in hundreds of repositories on GitHub.com.
@pewulfman @lildude @Alhadis can you review this?
Usage of the .jsligo extension is too low at the moment with six users contributing all but 58 files.
I'm happy to accept the other changes if you want to split the change of grammar from the addition of the new extension.
Can you please also update the OP to link to the source of the sample and explicitly stated the license of the file.
Can you please also update the OP to link to the source of the sample and explicitly stated the license of the file.
I did not completely understand, do you mean I need to add license information to the provided sample like (MIT License Copyright (c) 2020 LigoLANG SASU ... ) ?
Nope. Just fill in this part of the template that you've left empty:
I have included a real-world usage sample for all extensions added in this PR: Sample source(s): [URL to each sample source, if applicable] Sample license(s):
Usage of the
.jsligoextension is too low at the moment with six users contributing all but 58 files.I'm happy to accept the other changes if you want to split the change of grammar from the addition of the new extension.
I'll move this PR to Draft state for now, we are expecting the usage of JsLIGO to increase in the near future.
In a few months once we have enough usage of .jsligo I'll make this PR read, Thanks
Hey @lildude I see in the search query some users are excluded https://github.com/search?p=6&q=extension%3Ajsligo+-user%3Aemacsmirror+-user%3Aligolang+-user%3Atezos-checker+-user%3Amarigold-dev+-user%3Asmart-chain-fr+-user%3ADiningPhilosophersCo&type=Code
Is this done to check community adoption of jsligo?
Yes. That's removing the biggest contributors so we can get a better idea of overall usage as GitHub's search is struggling at the moment. See https://github.com/github/linguist/issues/5756 for the temporary criteria were using.
@lildude I am surprise about the user list that you removed from the query. I mean I understand that you remove ligolang but what about the others ? can you elaborate ?
What would be the minimum number of users and code files required to accept the PR ? The guideline says 200 user/repo
I'll start with this question...
What would be the minimum number of users and code files required to accept the PR ? The guideline says 200 user/repo
The 200 unique :user/:repo combination requirement is temporarily suspended in favour of the requirements detailed in https://github.com/github/linguist/issues/5756. .jsligo doesn't meet either of those requirement yet.
With that in mind, I'll answer:
@lildude I am surprise about the user list that you removed from the query. I mean I understand that you remove ligolang but what about the others ? can you elaborate ?
This is answered in https://github.com/github/linguist/issues/5756:
If particular users are showing a high proportion of the results, I'll manually filter out those users using -user:
to reduce their impact on my assessment.
To further elborate, I removed those just to demonstrate that of the current 1542 files on GitHub, six users are responsible for 1504 of them. This suggests the usage on GitHub is primarily isolated to a few users and not an a good indication of wide-spread adoption yet which is what we're aiming for.
Hey @lildude It's been around a year since I raised this PR, I see now there are 237 files according to this search url.
I am not able to find the number of users using .jsligo files the search url says 106M, Do you have some internal tool with which you can find the number of users?
Also is the current usage of .jsligo enough for this PR to be included into linguist (If yes I'll resolve the merge conflicts and make this PR ready)
Thanks.
Hey @lildude It's been around a year since I raised this PR, I see now there are 237 files according to this search url.
That's still very low, especially considering a repo can have multiple .jsligo files and as such isn't likely to meet our original requirements... even the temporarily relaxed requirements aren't be met.
Using the new search (it is still indexing repos from most recently active to least recently active so won't include everything yet) path:*.jsligo returns ~1.1k files. If we filter out just the two most prominent users as before path:*.jsligo -user:emacsmirror -user:ligolang
things drop quite significantly to 470 files. If we filter out all the users as before path:*.jsligo -user:emacsmirror -user:ligolang -user:tezos-checker -user:marigold-dev -user:smart-chain-fr -user:DiningPhilosophersCo we're down to 159 files.
I am not able to find the number of users using
.jsligofiles the search url says106M, Do you have some internal tool with which you can find the number of users?
I used to use a script but this is no longer possible due to problems with the old code search and the reason for the change in process as documented in https://github.com/github/linguist/issues/5756
So things are still not popular enough for inclusion.
Cool, Thanks for your response @lildude
Hi @lildude,
Checking for this topic. Do we have an idea how indexation works on Github ?
Looks like your request with extension got partial result for example this search result to 0 code, but this repo got jsligo file since 6 month.
Looks like I triggered manually indexation with path:*.jsligo repo:Laucans/Intezos-tutorial-1 :
But is the search request relevant ? Are you using another way to extract the number of distinct :user/:repo now ?
@Laucans No, I don't know how indexation works. This is maintained by a completely different team but I understand things will take time to index since we switched to using the new search functionality as active repositories are being prioritised with less active repos slowly being added as they're accessed or as the backlog is processed.
But is the search request relevant ? Are you using another way to extract the number of distinct
:user/:reponow ?
The search is still relevant (it needs slight tweaking to exclude forks) and I'm still using the same temporary approach I previously referenced as there still isn't an easy way to calculate the distinct repos.