Skip to content
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

Support spelling_language property #210

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

gustaphe
Copy link

I implemented the discussion in editorconfig/editorconfig#315 . Perhaps this is the wrong way around - it should be put in the standard first. But I don't know how to edit the standard, I know how to edit the implementation.

I'm currently running off my own fork, but in case the standard is updated at least this practical implementation is ready.

@xuhdev
Copy link
Member

xuhdev commented Mar 4, 2023

You are right, it need to be added to the spec first: spec.editorconfig.org. The plugin is a implementation of the spec for Vim.

@cxw42
Copy link
Member

cxw42 commented May 29, 2023

Draft specification change using spell_language (based on my reading of the thread): editorconfig/specification#41

@gustaphe
Copy link
Author

I don't know how the tests work, but there's a spelling_language in the specification now so here's the implementation.

@cxw42 cxw42 changed the title Add natural_language Support spelling_language property Mar 25, 2024
Copy link
Member

@cxw42 cxw42 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! I am just requesting one change. Thanks for this PR!

plugin/editorconfig.vim Outdated Show resolved Hide resolved
@gustaphe
Copy link
Author

gustaphe commented Apr 8, 2024

Sure, fixed this.

Just to mention, the specification is a bit vague on which territory codes are actually included, the ISO lists all of ^[a-z]\{2}\(-[A-Z0-9]\{2,3}\)\?$, but I'm limiting it to ^[a-z]\{2}\(-[A-Z]\{2}\)\?$ because it's the only ones that can be simply converted to vim format. And I've never seen the three letter or digit codes used. If that is ever required, somebody should probably build a lookup table for this.

@cxw42
Copy link
Member

cxw42 commented Apr 10, 2024

Thanks! As for two- vs. three-letter codes, I intended TT in

The format is ss or ss-TT

to be exactly two characters, but your point is well made --- TT could be read as a variable. I have opened editorconfig/specification#48 to fix that. Thank you for reporting the spec issue!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants