A collection of language packs for Vim.
One to rule them all, one to find them, one to bring them all and in the darkness bind them.
- It won't affect your startup time, as scripts are loaded only on demand*.
- It installs and updates 120+ times faster than the 203 packages it consists of.
- It is more secure because scripts loaded for all extensions are generated by vim-polyglot (ftdetect).
- Solid syntax and indentation support (other features skipped). Only the best language packs.
- All unnecessary files are ignored (like enormous documentation from php support).
- Automatically detect indentation (includes performance-optimized version of vim-sleuth)
- Each build is tested by automated vimrunner script on CI. See
spec
directory.
*To be completely honest, optimized ftdetect
script takes around 10ms
to load.
- Install Pathogen, Vundle, NeoBundle, or Plug package manager for Vim.
- Use this repository as submodule or package.
For example when using Plug:
Plug 'sheerun/vim-polyglot'
Optionally download one of the releases and unpack it directly under ~/.vim
directory.
You can also use Vim 8 built-in package manager:
mkdir -p ~/.vim/pack/default/start
git clone https://github.com/sheerun/vim-polyglot ~/.vim/pack/default/start/vim-polyglot
NOTE: Not all features of individual language packs are available. We strip them from functionality slowing vim startup (for example we ignore plugins
folder that is loaded regardless of file type, instead we prefer ftplugin
which is loaded lazily).
If you need full functionality of any plugin, please use it directly with your plugin manager.
- 8th
- a2ps
- a65
- aap
- abap
- abaqus
- abc
- abel
- acedb
- acpiasl
- ada
- ahdl
- aidl
- alsaconf
- aml
- ampl
- ansible
- ant
- apache
- apiblueprint
- applescript
- aptconf
- arch
- arduino
- art
- asciidoc
- asn
- aspperl
- aspvbs
- atlas
- autohotkey
- autoit
- automake
- ave
- awk
- basic
- blade
- brewfile
- bzl
- c/c++
- caddyfile
- carp
- cjsx
- clojure
- cmake
- coffee-script
- conf
- cpp-modern
- cql
- cryptol
- crystal
- csv
- cucumber
- cue
- dart
- dhall
- dlang
- dockerfile
- dosini
- elf
- elixir
- elm
- emberscript
- emblem
- erlang
- fennel
- ferm
- fish
- flatbuffers
- forth
- fsharp
- gdscript
- git
- gitignore
- glsl
- gmpl
- gnuplot
- go
- gradle
- graphql
- groovy
- grub
- haml
- handlebars
- haproxy
- haskell
- haxe
- hcl
- helm
- help
- hive
- html5
- htmldjango
- i3
- icalendar
- idris2
- idris
- ion
- javascript-sql
- javascript
- jenkins
- jq
- json5
- json
- jsonnet
- jst
- jsx
- julia
- kotlin
- ledger
- less
- lilypond
- livescript
- llvm
- log
- lua
- m4
- mako
- markdown
- mathematica
- mdx
- meson
- moonscript
- murphi
- nginx
- nim
- nix
- objc
- ocaml
- octave
- odin
- opencl
- perl
- pgsql
- php
- plantuml
- pony
- powershell
- prolog
- protobuf
- pug
- puppet
- purescript
- python-compiler
- python-indent
- python
- qmake
- qml
- r-lang
- racket
- ragel
- raku
- raml
- razor
- reason
- requirements
- rspec
- rst
- ruby
- rust
- sbt
- scala
- scss
- sh
- slim
- slime
- smt2
- solidity
- sql
- stylus
- svelte
- svg-indent
- svg
- swift
- sxhkd
- systemd
- tads
- terraform
- textile
- thrift
- tmux
- toml
- tptp
- trasys
- twig
- typescript
- unison
- v
- vala
- vbnet
- vcl
- velocity
- visual-basic
- vmasm
- vue
- xdc
- xml
- xsl
- yaml
- yard
- zephir
- zig
- zinit
You can either wait for new patch release with updates or run make
by yourself.
Please make sure you have syntax on
in your .vimrc
(or use something like sheerun/vimrc)
Individual language packs can be disabled by setting g:polyglot_disabled
as follows:
let g:polyglot_disabled = ['markdown']
The list of available languages to disable is shown above.
Please declare this variable before polyglot is loaded (at the top of .vimrc)
If you wish to use filetype detection by Vim Polyglot but you'd like to use your own syntax-highlighting plugin, you can append .plugin
to disabled entry, like below. Disabling Vim Polyglot filetype plugin won't disable native Vim filetype plugin.
let g:polyglot_disabled = ['markdown.plugin']
Please note that disabling a language won't make in your vim startup any faster / slower (only for specific this specific filetype). All plugins are lazily loaded only when they are really needed.
Vim Polyglot tries to automatically detect indentation settings (just like vim-sleuth). If this feature is not working for you for some reason, please file an issue and disable it temporarily with:
let g:polyglot_disabled = ['autoindent']
Language packs are periodically updated using automated scripts/build
script.
Feel free to add your language to packages.yaml
+ heuristics.yaml
, and send pull-request. You can run make test
to run rough tests. And make dev
for easy development.
See linked repositories for detailed license information. This repository is MIT-licensed.