Since flash, while integral to my day-to-day editing is not about providing a _base_ to other plugins, but editing, it moved to the editing module. Spellsync is only really useful in a prose context in my workflows, so this is where it went.
145 lines
3.1 KiB
Lua
145 lines
3.1 KiB
Lua
return {
|
|
-- surround things with other things using ys/cs/ds
|
|
{ "kylechui/nvim-surround", config = true, event = { "CursorHold", "InsertEnter" } },
|
|
|
|
-- jump between letters with improved fFtT quicksearch, mimics sneak
|
|
{
|
|
"folke/flash.nvim",
|
|
event = "VeryLazy",
|
|
opts = {
|
|
modes = {
|
|
search = {
|
|
enabled = false,
|
|
},
|
|
},
|
|
},
|
|
keys = {
|
|
{
|
|
"s",
|
|
mode = { "n", "x" },
|
|
function()
|
|
require("flash").jump()
|
|
end,
|
|
desc = "Flash",
|
|
},
|
|
{
|
|
"S",
|
|
mode = { "n", "x", "o" },
|
|
function()
|
|
require("flash").treesitter()
|
|
end,
|
|
desc = "Flash Treesitter",
|
|
},
|
|
{
|
|
"r",
|
|
mode = "o",
|
|
function()
|
|
require("flash").remote()
|
|
end,
|
|
desc = "Remote Flash",
|
|
},
|
|
},
|
|
},
|
|
-- extend the ^x / ^a possibilities to dates, hex, alphabets, markdown headers
|
|
-- REMAPPED TO C-X / C-S for decrement/increment
|
|
{
|
|
"monaqa/dial.nvim",
|
|
version = false,
|
|
config = function()
|
|
local augend = require("dial.augend")
|
|
require("dial.config").augends:register_group({
|
|
-- default augends used when no group name is specified
|
|
default = {
|
|
augend.integer.alias.decimal,
|
|
augend.integer.alias.hex,
|
|
augend.hexcolor.new({ case = "lower" }),
|
|
augend.date.alias["%Y/%m/%d"],
|
|
augend.date.alias["%Y-%m-%d"],
|
|
augend.date.alias["%m/%d"],
|
|
augend.date.alias["%H:%M:%S"],
|
|
augend.date.alias["%H:%M"],
|
|
augend.constant.alias.de_weekday_full,
|
|
augend.constant.alias.de_weekday,
|
|
augend.semver.alias.semver,
|
|
augend.constant.alias.Alpha,
|
|
augend.constant.alias.alpha,
|
|
augend.constant.alias.bool,
|
|
augend.constant.new({
|
|
elements = { "and", "or" },
|
|
word = true, -- if false, "sand" is incremented into "sor", "doctor" into "doctand", etc.
|
|
cyclic = true, -- "or" is incremented into "and".
|
|
}),
|
|
augend.constant.new({
|
|
elements = { "&&", "||" },
|
|
word = false,
|
|
cyclic = true,
|
|
}),
|
|
augend.constant.new({
|
|
elements = { "- [ ] ", "- [x] ", "- [o] ", "- [-] ", "- [~] " },
|
|
word = false,
|
|
cyclic = true,
|
|
}),
|
|
},
|
|
})
|
|
end,
|
|
event = { "CursorHold", "InsertEnter" },
|
|
keys = {
|
|
{
|
|
"<C-s>",
|
|
function()
|
|
require("dial.map").manipulate("increment", "normal")
|
|
end,
|
|
mode = "n",
|
|
},
|
|
{
|
|
"<C-x>",
|
|
function()
|
|
require("dial.map").manipulate("decrement", "normal")
|
|
end,
|
|
mode = "n",
|
|
},
|
|
{
|
|
"<C-s>",
|
|
function()
|
|
require("dial.map").manipulate("increment", "visual")
|
|
end,
|
|
mode = "v",
|
|
},
|
|
{
|
|
"<C-x>",
|
|
function()
|
|
require("dial.map").manipulate("decrement", "visual")
|
|
end,
|
|
mode = "v",
|
|
},
|
|
{
|
|
"g<C-s>",
|
|
function()
|
|
require("dial.map").manipulate("increment", "gnormal")
|
|
end,
|
|
mode = "n",
|
|
},
|
|
{
|
|
"g<C-x>",
|
|
function()
|
|
require("dial.map").manipulate("decrement", "gnormal")
|
|
end,
|
|
mode = "n",
|
|
},
|
|
{
|
|
"g<C-s>",
|
|
function()
|
|
require("dial.map").manipulate("increment", "gvisual")
|
|
end,
|
|
mode = "v",
|
|
},
|
|
{
|
|
"g<C-x>",
|
|
function()
|
|
require("dial.map").manipulate("decrement", "gvisual")
|
|
end,
|
|
mode = "v",
|
|
},
|
|
},
|
|
},
|
|
}
|