Michael Mogenson
37ded5e400
Check if buffile is path before loading editorconfig settings
...
Check if buffile is a full path by checking for the beginning
'/' character in editorconfig-load command. This avoids a parsing
error from feeding a *scratch*/*debug*/*grep*/etc. buffer name to the
editorcofig command. Don't clear editorconfig hooks until after checking
for a valid bufffile path. This way, opening the *debug* buffer will
not clear the hooks from a previously parsed .editorconfig file. If
trim_trailing_whitespace is true, print the hook directly from awk. This
removes the need to save a editorcofig_trim_trailing_whitespace option.
Note: Setting the max_line_length requires a window to be created.
Therefore, a global hook to load .editorconfig settings should be:
hook global WinCreate .* %{editorconfig-load}
2019-08-20 14:55:17 -04:00
Maxime Coste
292efe1b37
Merge remote-tracking branch 'andreyorst/patch-2'
2019-08-19 22:30:16 +10:00
Maxime Coste
7d8fb135a9
Merge remote-tracking branch 'codesoap/makefile'
2019-08-19 22:25:18 +10:00
Maxime Coste
5e2f123baf
Merge branch 'master' of https://github.com/aecepoglu/kakoune
2019-08-19 22:24:14 +10:00
Maxime Coste
349586b464
Merge remote-tracking branch 'andreyorst/fix-rust-meta-attributes'
2019-08-19 22:20:13 +10:00
Maxime Coste
0f5389700e
Merge remote-tracking branch 'nhey/master'
2019-08-19 22:19:29 +10:00
Andrey Orst
427153b8e9
remove wrong '+' from awk regex
2019-08-12 22:18:26 +03:00
nhey
4722db7103
Highlight parenthesized paths. Also change '()' to '§' for module quoting.
2019-08-12 18:07:32 +02:00
tawsi-melek
3f405b00f1
Revert back to previous char literal highlighter as it's more precise
2019-08-12 17:17:20 +02:00
tawsi-melek
228a8dd9ae
Fix some more edge cases
...
* Adapt the char literal highlighter from c-family.kak
* Fix line comment adjacent to char literal not being highlighted
* Fix single quote terminating a double quote string
2019-08-12 16:40:35 +02:00
tawsi-melek
1c58e5aa90
Improve single line comments
...
* '#' now gets highlighted as a char literal
* Remove highlighting for comment tags and escape sequences
2019-08-08 22:47:22 +02:00
tawsi-melek
93e64b4541
Some more improvements
...
* Fix keywords in comments being highlighted
* Highlight Nim's escape sequences for strings
* Highlight common comment tags
* Add on/off to the highlighted boolean values
* Remove redundant regex highlighter for comments
* Fix autoindent indenting lines more than it should
2019-08-08 21:17:55 +02:00
Andrey Orst
396236f728
support raw strings withing the meta attributes
2019-08-07 11:37:02 +03:00
Andrey Orst
3156ecacc3
fix #3043
2019-08-06 17:02:51 +03:00
tawsi-melek
5ca0b9baa3
Enum too
2019-08-06 00:00:38 +02:00
tawsi-melek
ff7397b593
nim.kak: Add auto-indent after tuple and object
...
Before:
```nim
type
MyType = tuple
myint: int # This line needs to be indented manually
```
After:
```nim
type
MyType = tuple
myint: int # Lines after 'tuple' are now indented automatically
```
2019-08-05 22:02:56 +02:00
Maxime Coste
6eec6e656d
Merge remote-tracking branch 'lenormf/fix-python-decorators'
2019-08-04 20:21:20 +10:00
Jason Felice
ba672623bc
Insert Clojure ns directive for new files
2019-07-31 09:38:09 -04:00
codesoap
e502097d01
makefile.kak: require whitespace after target
2019-07-30 14:43:11 +02:00
codesoap
6e86766966
makefile.kak: remove reqex mismatch between highlight and indent
2019-07-30 10:00:04 +02:00
codesoap
4c3795faa2
makefile.kak: Refine regex for target
...
Multiple targets and the target separators ':', '::' and '!' are now
supported.
2019-07-30 09:55:25 +02:00
Frank LENORMAND
ff52bd7027
rc python: Highlight indented decorators with .
...
Make sure decorators are on their own line, and don't stop highlighting at
the first dot when they are imported, e.g.
```
import enum
@enum.unique
class A(enum.Enum):
…
```
Ideally highlighting shouldn't stop at the first parenthesis either
(e.g. `@foo(['1'])`), but the current code somewhat highlights the contents
of the parens already, which is good enough in most cases.
2019-07-26 13:01:58 +03:00
Maxime Coste
550feb1706
Merge remote-tracking branch 'andreyorst/rust-highlighting'
2019-07-25 17:48:04 +10:00
Maxime Coste
6e1e79ed19
Merge branch 'master' of http://github.com/cglogic/kakoune
2019-07-25 17:26:41 +10:00
Oleh Hushchenkov
8fc705d4cc
Fix c-family indent on opening curly brace after if-else
2019-07-25 09:58:33 +03:00
Maxime Coste
65327da4cf
Merge remote-tracking branch 'laelath/markdown-lazy-load'
2019-07-24 17:38:00 +10:00
Justin Frank
a15ff0ffc3
Move module aliases to after main module definition
2019-07-22 23:48:30 -07:00
Justin Frank
8941002ce0
Give hooks a group so they're cleaned up
2019-07-22 19:03:04 -07:00
Justin Frank
89b50daa66
Use module alias pattern for markdown dynamic loading
2019-07-22 19:01:40 -07:00
aecepoglu
8691c1557a
ocaml.kak fix '"' and char literals
2019-07-22 23:49:15 +03:00
Andrey Orst
677d1efb23
move regex highlighters to the top, add method, field and function hl
2019-07-22 22:32:26 +03:00
codesoap
090c0b4db1
Allow / in target when highlighting in makefile.kak
2019-07-22 17:32:25 +02:00
Andrey Orst
3c0a350079
require module the old way
2019-07-22 18:22:44 +03:00
Andrey Orst
a81eb158be
extend Rust highlighting
2019-07-22 15:56:29 +03:00
Maxime Coste
837416ea38
Merge remote-tracking branch 'MarSoft/nix-syntax'
2019-07-21 12:36:56 +10:00
Maxime Coste
d05ef24471
Merge remote-tracking branch 'gaeulbyul/css-comment'
2019-07-21 12:34:28 +10:00
Maxime Coste
268af7f61c
Merge remote-tracking branch 'lenormf/patch-1'
2019-07-21 12:14:57 +10:00
Maxime Coste
27fce78eac
Merge remote-tracking branch 'codesoap/ledger'
2019-07-21 12:08:42 +10:00
Gaeulbyul
bd257ceb7d
css.kak: Highlight comment inside declaration
2019-07-18 01:33:57 +09:00
codesoap
0bd57817b3
Configure comment_line for the ledger filetype
2019-07-12 14:02:06 +02:00
David Ross
27ed20582f
Add complete extra_word_chars for lisp
...
See https://www.cs.cmu.edu/Groups/AI/html/cltl/clm/node27.html .
2019-07-06 12:25:46 -07:00
David Ross
e65740873d
Treat '-' as an word character in lisp
...
'-' is part of identifiers in most or all lisps.
Strategy for implementing this copied from https://github.com/mawww/kakoune/blob/master/rc/filetype/scss.kak#L20 .
2019-07-05 06:44:45 -07:00
codesoap
2d15c13c1e
ledger.kak: Automatically indent postings in transactions
2019-07-02 09:49:52 +02:00
codesoap
710ebabcb8
Add ledger filetype
2019-07-01 20:49:55 +02:00
Frank LENORMAND
a735c06714
rc git: Fix the indentation of misaligned commands
2019-07-01 12:56:51 +00:00
Maxime Coste
5c219cc743
Merge remote-tracking branch 'sjjf/sh_indent_v2'
2019-07-01 22:00:31 +10:00
Maxime Coste
2e3e0c47bb
Merge remote-tracking branch 'greenfork/fix-ruby-end-autoinsertion'
2019-06-30 10:30:40 +10:00
Simon Fowler
b2459f5ecb
Remove the sh_auto_indent option.
...
We now auto indent by default, with the option to disable it handled by
the `diabled_hooks` mechanism.
2019-06-29 12:34:14 +10:00
codesoap
ca2741fe20
Rename ModuleLoad hook to ModuleLoaded
...
This clarifies, that the hook is run *after* the module is loaded.
2019-06-25 19:16:47 +02:00
Frank LENORMAND
e5b9761818
rc filetype d: Highlight quoted backticks properly
...
Fixes #2970
2019-06-24 10:18:43 +03:00