tweekmonster / impsort.vim

Sort and highlight Python imports in Vim
MIT License
37 stars 6 forks source link

[WIP] Import types #5

Closed tweekmonster closed 8 years ago

tweekmonster commented 8 years ago

Resolves #4

tweekmonster commented 8 years ago

@petobens I'm moving the discussion here.

Could you try running :set syntax=python to see if it resets? If not, try: :runtime! after/syntax/python.vim

Only thing I can think of is some other syntax script is clearing it or is causing this plugin's after/syntax/python.vim script to not get sourced. Do you happen to have some other after/syntax/python.vim script that's being sourced?

One last thing to try is showing me what :echo &iskeyword is set to.

petobens commented 8 years ago

Mmmm, I think the syntax script is correctly sourced (I don't have any other /after/syntax/python.vim script and :syntax list imposortNonImport shows the correct hl groups).
Is there a way yo check the last sourced syntax script?

echo &iskeyword returns @,48-57,_,192-255.

If this is the only thing stopping you from merging into master please proceed since it's probably a problem on my end.

tweekmonster commented 8 years ago

@petobens I'm able to reproduce the problem. It's just a matter of sorting it out now. I wasn't seeing this because I was using a different python syntax: https://github.com/hdima/python-syntax

Telling people to use it isn't an acceptable solution, so I'll try to figure out why the builtin syntax is messing it up after this merged. Thanks for all your input!