gnull / surround.kak

A mirror of https://github.com/alexherbo2/surround.kak

Repository from Github https://github.comgnull/surround.kakRepository from Github https://github.comgnull/surround.kak

surround.kak

Surround mode for Kakoune.

Installation

Add surround.kak to your autoload or source it manually.

require-module surround

Usage

  • Enter surround mode with enter-user-mode surround.
  • Enter insert mode with surround-enter-insert-mode.

Configuration

# Quoting
map -docstring 'Surround' global normal q ': enter-user-mode surround<ret>'
map -docstring 'Surround insert' global normal Q ': surround-enter-insert-mode<ret>'

# Move macros to ^
map -docstring 'Play macro' global normal ^ q
map -docstring 'Record macro' global normal <a-^> Q

Surrounding pairs

By default, surround.kak includes the following surrounding pairs:

Parenthesis block: b ( )
Braces block: B { }
Brackets block: r [ ]
Angle block: a < >
Double quote string: Q " "
Single quote string: q ' '
Grave quote string: g ` `
Double quotation mark: <a-Q> “ ”
Single quotation mark: <a-q> ‘ ’
Double angle quotation mark: <a-G> « »
Single angle quotation mark: <a-g> ‹ ›
Emphasis: _ _
Strong: ** **
Regular expression: / /

surround.kak has also support for free input on i and m (mirror), and tags on t.

See also auto-pairs.kak and manual-indent.kak.

About

A mirror of https://github.com/alexherbo2/surround.kak

License:The Unlicense