Commit Graph

8877 Commits

Author SHA1 Message Date
SeerLite
aa22ea58cf doc options: Clarify how to empty lists/maps 2020-10-27 16:08:16 -03:00
Tilman List
9955cfdd8d changed scope of tmux_repl_id from global to current
By setting the tmux_repl_id in the `current` scope it is possible to have
different REPLs for different buffers or windows.
2020-10-27 17:20:33 +01:00
Tilman List
a5549f32bf listentolist Copyright Waiver
I dedicate any and all copyright interest in this software to the
public domain.  I make this dedication for the benefit of the public at
large and to the detriment of my heirs and successors.  I intend this
dedication to be an overt act of relinquishment in perpetuity of all
present and future rights to this software under copyright law.
2020-10-27 14:26:35 +01:00
Tilman List
de6e86da46 changed the way the x11 REPL interaction works
Now it uses the window id to identify the REPL window. It is stored in
the option x11_repl_id. That way it is possible to have different REPLs
for different buffers or windows.
2020-10-27 14:26:27 +01:00
Cedric Sodhi
221fc38bd9 Disabled backtick escaping
Fixes issue #2377 by removing the ability to escape backticks in backticks in compliance with asciidoc's behaviour. Adjusted hooks.asciidoc, keys.asciidoc, and command-parsing.asciidoc to match accordingly.
2020-10-27 12:36:33 +01:00
Maxime Coste
90043e7df0 Replace write -atomic with write -method <method>
`-atomic` becomes `-method replace` and `-method overwrite` is now
supported explicitely instead of only available through the
writemethod option.

Fixes #3827
2020-10-27 20:20:18 +11:00
Frank LENORMAND
f8a2176ed1 rc markdown: Highlight inline code blocks properly
This commit allows code blocks to be prefixed with tabulation
characters to be picked up and highlighted by the editor.

Indenting caused by the inclusion of an inline code block into a
list item is also taken into account. However, that might cause false
positives, for example with a hard wrapped list item indented with
an amount of spaces congruent to 4.
2020-10-23 16:35:01 +03:00
Frank LENORMAND
b36f7b8440 rc kakrc: Highlight numbers 2020-10-23 14:31:38 +03:00
Frank LENORMAND
72e2b4a9be rc kakrc: Highlight str-to-str-map types 2020-10-23 14:28:43 +03:00
YI
489773dbf4 remove extra double quotes in expansion documentation 2020-10-22 09:03:20 +08:00
Johannes Altmanninger
637153270f rc git: indented # is not a comment in commit message
Git includes them in commit messages and notes, which is sometimes useful
when adding shell script snippets:

    # this is included in the commit message!

Also, in rebase buffers, # only marks a comment if it is the first nonblank
character in a line.
2020-10-21 22:08:35 +02:00
Maxime Coste
9a5cf2fc9f Support explicit register for :, |, ! and $ commands
Giving an explicit register uses its content for the default value
to use if the user does not enter anything. This enables:

`set-register a %{commands}; execute-keys '"a:<ret>'`
`set-register a %{shell script}; execute-keys '"a|<ret>'`
...

This provides a nice way to avoid the need to escape keys to use
those normal mode commands.

Fixes #3825
2020-10-20 21:56:51 +11:00
Maxime Coste
354cfd3b8f Disable auto-insertion of menu completion when no text was entered
This avoids a frustrating behaviour where Kakoune autoinserts the first
command name when hitting <space> after a ; in a command line. It also
fixes the empty prompt case that was auto-completed instead of executing
the default command.
2020-10-20 21:43:34 +11:00
Maxime Coste
4d22b405d6 Notify prompt completion changes in startup message 2020-10-20 21:05:26 +11:00
Johannes Altmanninger
816bdc91f6 rc fish.kak: split fish-insert hook out from fish-indent
Same as in sh.kak; this allows to only disable the insert hook using
%opt{disabled_hooks}.
2020-10-19 19:01:17 +02:00
Johannes Altmanninger
335ee743a4 Fix overzealous closing of ruby heredocs
Fixes #2516
2020-10-19 19:01:17 +02:00
Johannes Altmanninger
19391f8c02 rc perl: quoted heredocs can be empty
Also the closing line cannot have any trailing characters.
Leading tabs are allowed if <<~ is used.
2020-10-19 19:01:17 +02:00
Jason Felice
b6df40c586 rc nix: dash in extra_word_chars 2020-10-19 11:53:08 -04:00
Nicolas Ouellet-payeur
4a59db1bd1 Fix wcwidth() compile error with MSYS2
We try to detect when compiling under Cygwin, so we can set the
_XOPEN_SOURCE define which lets us use wcwidth(). We look for the
string "CYGWIN" in the uname, which looks like:

    CYGWIN_NT-10.0

MSYS2 is also based on Cygwin, so all of the above should still work.
However, we detect Cygwin by looking for the string "CYGWIN" in the
uname. In MSYS2, the uname looks like:

    MSYS_NT-10.0-18362

This patch looks for the string "_NT" instead of the string "CYGWIN"
in the uname, since it's common to both environments. This fixes a
compilation error on MSYS2.
2020-10-19 09:36:25 -04:00
Maxime Coste
65587d1eee Auto-insert best completion on space for menu completions
The menu flag signifies that only the completions are valid arguments,
hence it makes sense to auto insert the best one on space.

Because full match is always considered the best match in completion
ranking, this should always have a reasonable behaviour.

This makes it harder to enter a hidden command, but completion can
always be disabled via <c-o> or by quoting in those rare cases.
2020-10-19 21:43:03 +11:00
Maxime Coste
2cd323b314 Allow quiting last client with unsaved buffer in daemon mode
Because the server will out-live that client's disconnection it
is still ok to have modified buffers, the server will complain
on `kill`.

Fixes #3801
2020-10-19 20:39:25 +11:00
Maxime Coste
97e88b6087 Remove the rename-client's nc alias
Closes #3789
2020-10-19 20:30:33 +11:00
Maxime Coste
296937a2a2 Merge remote-tracking branch 'Carsenal/perl_regex_highlighters' into master 2020-10-19 20:23:57 +11:00
Maxime Coste
a716923546 Merge remote-tracking branch 'SeerLite/markdown-raw-attributes' into master 2020-10-19 20:23:11 +11:00
Maxime Coste
8153f34a04 Merge remote-tracking branch 'voroskoi/gopls-fix' into master 2020-10-19 20:09:31 +11:00
Maxime Coste
2f8e8e542a Merge remote-tracking branch 'johnisom/sql-highlighting' into master 2020-10-19 20:08:50 +11:00
Maxime Coste
61f08e84f8 Merge remote-tracking branch 'eraserhd/nix-dash-fix' into master 2020-10-19 20:08:18 +11:00
Maxime Coste
def37a6ff4 Merge remote-tracking branch 'm-kru/vhdl' into master 2020-10-19 20:06:25 +11:00
Maxime Coste
f549190a98 Add support for explicit completion in prompt mode 2020-10-19 19:36:58 +11:00
voroskoi
dd6a275c3e
gopls.kak: use nop for removing temp dir
Co-authored-by: Frank LENORMAND <1379068+lenormf@users.noreply.github.com>
2020-10-17 09:47:07 +02:00
VÖRÖSKŐI András
cbbab07aab gopls: Fix format/imports error reporting
Remove unnecessary single quotes and whitespaces in %file{}
Do not delete error file before sending to debug buffer
Fix gopls definition error handling and empty sting check
Silence shellcheck warnings
2020-10-16 22:40:58 +02:00
Michał Kruszewski
4aabe33a24 Add support for VHDL filetype. 2020-10-15 09:21:04 +02:00
John Isom
860e8d55eb Fix function highlighting by adding lazy instead of greedy regexp quantifier 2020-10-14 14:54:43 -06:00
Jason Felice
c1f67972e4 rc nix: handle dashes embedded in identifiers
Some experimentation at the REPL showed that any number of leading dashes
are operators, while embedded dashes are identifier characters.

Closes #3803.
2020-10-14 07:55:06 -04:00
Maxime Coste
1de058cdf8 Fix rust highlighting after regions highlighter behaviour change 2020-10-12 13:04:08 +11:00
Maxime Coste
f6c67f7831 Code cleanup in insert completer 2020-10-12 12:41:52 +11:00
Maxime Coste
246a32797a Fix region regexes incorrectly matching ^$ at end of line
Because no flags were set for regex matching, the regex engine was
assuming that the subject string past-the-end matched a end-of-line.
As the subject string already ended with a \n character, the regex
engine processing of the "past-the-end" position would match '^$'
as ^ matched past the existing \n and $ matched the assumed
end-of-line.

Fixes #3799
2020-10-12 12:41:21 +11:00
SeerLite
a06dcf8c10 markdown.kak: Support pandoc's raw_attribute 2020-10-11 20:53:39 -03:00
Carson Riker
21fbda7c68 Fixed ending of region, as per @krobelus 2020-10-09 13:25:26 -04:00
Carson Riker
30d5aa203d Added highlighted for curly-brace based sregexes 2020-10-09 10:45:42 -04:00
Carson Riker
be154ca86d Carson Riker Copyright Waiver
I dedicate any and all copyright interest in this software to the
  public domain.  I make this dedication for the benefit of the public at
  large and to the detriment of my heirs and successors.  I intend this
  dedication to be an overt act of relinquishment in perpetuity of all
  present and future rights to this software under copyright law.
2020-10-09 10:43:35 -04:00
Maxime Coste
600be827b3 Merge remote-tracking branch 'pickfire/indent-yaml' into master 2020-10-08 19:51:05 +11:00
Maxime Coste
7fefb206dc Merge remote-tracking branch 'SeerLite/lua-fixes' into master 2020-10-08 19:50:41 +11:00
Maxime Coste
1635ddab78 Merge remote-tracking branch 'pickfire/indent-rust' into master 2020-10-08 19:39:03 +11:00
Ivan Tham
c148fdbe9a Rust always indent after { 2020-10-04 23:40:49 +08:00
Delapouite
8989febe7a doc: mention comma key for entering user-mode 2020-10-04 13:34:57 +02:00
Ivan Tham
b0ae30a443 Add missing rust indent after function { 2020-10-04 14:19:33 +08:00
SeerLite
3c3a4ec985 lua.kak: Correct -trim-indent hook and fix indent 2020-10-03 16:38:43 -03:00
SeerLite
84054f9e3e SeerLite Copyright Waiver
I dedicate any and all copyright interest in this software to the
public domain.  I make this dedication for the benefit of the public at
large and to the detriment of my heirs and successors.  I intend this
dedication to be an overt act of relinquishment in perpetuity of all
present and future rights to this software under copyright law.
2020-10-03 16:36:46 -03:00
Ivan Tham
1809035c15 Yaml indent after - 2020-10-02 14:24:04 +08:00