Skip to content
Frank LENORMAND edited this page May 1, 2020 · 41 revisions

The programming languages listed on this page have built-in support in kakoune through the use of rc files.

This encompass such common operations as highlighting, indenting, tagging, building, debugging, linting…

Columns in the following table:

  • Name: points to the source file of the related kak script.
  • Alt File: the script creates an alt command to switch between related buffers, for example switching between .c and .h files in C.
  • lintcmd: the language can be linted by this command external tool.
  • formatcmd: the language can be formatted through this external command, but you need to plug in explicitly in your kakrc. Example with rust using a hook (note that this hook is added upstream):
hook global WinSetOption filetype=rust %{
  set window formatcmd 'rustfmt'
}
Name Alt File formatcmd lintcmd
AsciiDoc
C astyle cppcheck
cppcheck --language=c --enable=warning,style,information --template='{file}:{line}:{column}: {severity}: {message}' --suppress='*:*.h' --suppress='*:*.hh' 2>&1
GNU indent
C++ astyle cppcheck
cppcheck --language=c++ --enable=warning,style,information --template='{file}:{line}:{column}: {severity}: {message}' --suppress='*:*.h' --suppress='*:*.hh' 2>&1
Clojure
CoffeeScript coffeelint
CSS prettier stylelint
D dfmt
dfmt
D-Scanner
dscanner -S --errorFormat '{filepath}:{line}:{column}: {type}: {message}'
elixir
elm elm-format
fish fish_indent
Go gofmt golint
HAML
HTML reshape
Handlebars
Haskell hlint
INI
Java checkstyle
JavaScript prettier eslint
JSON jq
prettier
Julia
Latex
Lua
LISP
Makefile
Markdown
MoonScript
Nim
Ocaml ocp-indent
Perl perltidy
PHP
Python autopep8 flake8
flake8 --filename='*' --format='%%(path)s:%%(row)d:%%(col)d: error: %%(text)s' --ignore=E121,E123,E126,E226,E24,E704,W503,W504,E501,E221,E127,E128,E129,F405
black
Pony
Pug
Ragel
Ruby rubocop
rubocop -x -o /dev/null -s '${kak_buffile}' | sed -n '2,$p'
rubocop
rubocop -l --format emacs
Rust rustfmt
SASS & SCSS prettier
Scala
Shell shellcheck
shellcheck -fgcc -Cnever
Swift
TUP
YAML prettier

Languages supported by the community:

Clone this wiki locally