Hi,
There are quite a few Issues/Pull Requests on Github about adding more extensions to `filetype_extensions.conf` so various types of files are detected/colourized/symbolized properly out of the box.
IMO, we need a policy/guidance on what is acceptable. The way I see it there are a few ways we could handle it:
1) Add all filetype extensions possible as long as there's proof somewhere they actually exist/are used.
2) Add only popular, generic ones, for example JSON or YAML or actual programming languages supported by Geany.
3) Don't add anymore except when adding entirely new filetype support; the `filetype_extensions.conf` file is user-editable precisely for this reason.
I don't really have an opinion on this, but it would be helpful to have some kind of consensus/policy on it, for the purposes of triaging Issues and Pull Requests on Github.
Regards, Matthew Brush
On 21 December 2017 at 09:09, Matthew Brush mbrush@codebrainz.ca wrote:
Hi,
There are quite a few Issues/Pull Requests on Github about adding more extensions to `filetype_extensions.conf` so various types of files are detected/colourized/symbolized properly out of the box.
IMO, we need a policy/guidance on what is acceptable.
Agreed, I have been taking the most conservative approach since its harder to remove things once added, than it is to add them later if we change our minds. Having an actual policy would be a good thing, though it probably would still involve some judgement.
The way I see it there are a few ways we could handle it:
- Add all filetype extensions possible as long as there's proof somewhere
they actually exist/are used.
- Add only popular, generic ones, for example JSON or YAML or actual
programming languages supported by Geany.
This would be my proposed approach, add extensions that correspond to actual filetypes, but NOT add every extension for every JS framework to the JS filetype and every extension of every Python framework to the Python filetype etc. And of course once one is added they all have to be added or the project is choosing winners amongst other projects.
Languages that are actually subsets of others, eg JSON for JS and Cython for Python are ok to just add to filetype.extensions.
But adding extensions for languages that only approximately correspond to the filetype they are added to, is just making a promise that Geany can't keep, and will only likely lead to user disappointment. That also applies to new versions of languages that are not mostly backward compatible with the version currently in Geany.
Anything else should make a custom filetype.
- Don't add anymore except when adding entirely new filetype support; the
`filetype_extensions.conf` file is user-editable precisely for this reason.
Users of frameworks should be encouraged to make custom filetypes that fall back to the right base filetype, add extra wordlists, and are supported with tags for their APIs and maintained on the wiki by an expert in them. Users who install those custom filetypes can then add them to their personal filetypes.extensions without every Geany user who has no need of them having to pay the cost.
Also the framework expert mostly isn't the Geany devs, so getting bug reports on Geany github is really wasting the posters time, hence the suggestion of the wiki, or maybe a separate repo like themes/plugins.
I don't really have an opinion on this, but it would be helpful to have some kind of consensus/policy on it, for the purposes of triaging Issues and Pull Requests on Github.
+1 Thanks for raising it.
Cheers Lex
Regards, Matthew Brush _______________________________________________ Devel mailing list Devel@lists.geany.org https://lists.geany.org/cgi-bin/mailman/listinfo/devel
On 21.12.2017 00:09, Matthew Brush wrote:
- Add all filetype extensions possible as long as there's proof
somewhere they actually exist/are used.
+1
In past we did not add some dialects of e.g. diff as they do have a different meaning in Debian and (IIRC) Gentoo and these distributions are having their own patchsets for. But in general I don't see big issues adding new extensions for filetypes we already support.
Cheers, Frank