Skip to content

Polyglot overrides newer ftplugins that ship with vim #845

@idbrii

Description

@idbrii

Does this bug happen when you install plugin without vim-polyglot?
No, it's because polyglot bundles ftplugins that are included with vim.

Readme says:

On top of all language packs from vim repository, vim-polyglot includes...

Describe the bug:

When I upgrade vim it gets new syntax and ftplugin files, but since user plugins load before vim runtime files the polyglot version is preferred. So my ftplugin files will be using the old polyglot version.

I can upgrade polyglot to solve, but I've had several issues upgrading polyglot that broke my workflow so it doesn't feel safe to upgrade without carefully checking the change log. (Automatic indent detection was a notable one since I already have DetectIndent and editorconfig and I think polyglot overrode their behaviour. I think Sensible was another fiasco since I see I've disabled that too.)

To Reproduce:

Install latest vim. Install polyglot c96947b.

Create test.story:

Feature: Guess the word
  Rule: Only 5 guesses

  # The first example has two steps
  Scenario: Maker starts a game
    When the Maker starts a game
    Then the Maker waits for a Breaker to join

It looks like this:
polyglot

but should look like this with Rule highlighted:
vim latest with Rule highlighted

Suggestions:

Provide a way to disable polyglot's copy of vim's language packs or grab the version of vim they're copied from and automatically disable if the user's version of vim is newer.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions