-
Notifications
You must be signed in to change notification settings - Fork 297
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
Get scripts/build working again, make the tests pass #844
Open
00dani
wants to merge
14
commits into
sheerun:master
Choose a base branch
from
00dani:feature/fix-build
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This is one of the more drastic changes to the build process, but it seems to be a good one. Having two copies of the same filetype can cause a variety of problems since Vim tries to load both of them - for example, :setf ada will error if you have mainline vim-polyglot installed, because the Ada autoload file uses :lockvar. Not copying the filetype support that's bundled with Vim already prevents that collision issue. This change also means you can immediately get the latest version of the natively-supported filetypes if you keep your Vim up to date, while the version bundled into vim-polyglot is still pinned at v8.2.4274 for compatibility reasons. (I did try bumping up that version number, but you end up getting Vim9 script, which will break vim-polyglot on older Vims.)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I noticed there hasn't been an update to vim-polyglot in about a year, and that the test suite was failing, so I figured I'd try to fix both issues. There were some obvious issues, like calling
File.exists?
rather thanFile.exist?
in the build script, but I've made some somewhat more drastic changes as well.Most notably, all
native
packages aren't copied into vim-polyglot itself any more, because that causes conflicts between the version supplied by Vim and the version supplied by vim-polyglot. For example, running:setf ada
with the mainline version of vim-polyglot will error, because Vim will load both its own version of the Ada plugin and vim-polyglot's version, and that plugin uses:lockvar
so you get a crash.I've also tweaked the test suite slightly to make it more robust, and I've taught
generate_ftdetect
to include suitable autocommands for filetypes Vim natively knows about but vim-polyglot does not, such as Factor, Hack, and Twig.Finally I ran a build and committed the updated vim-polyglot, which now passes all its tests.