Skip to content

mrbeardad/nvim-multi-cursor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 

Repository files navigation

nvim-multi-cursor

Features

  • Implement by using macro recording
  • Repeat your action at each virtual cursor, support all of your customized keymaps
  • Press q to quit multi-cursor-mode
  • TODO: currently only support normal mode, the actions in insert mode or visual mode will be synced to virtual cursor when you return to normal mode.

Installation

Example with lazy.nvim

  {
    "mrbeardad/nvim-multi-cursor",
    dependencies = { { "folke/flash.nvim", opts={} } },
    keys = {
      {
        "<C-j>",
        function()
          require("nvim-multi-cursor").toggle_cursor_downward()
        end,
        mode = { "n" },
        desc = "Toggle Cursor Downward",
      },
      {
        "<C-k>",
        function()
          require("nvim-multi-cursor").toggle_cursor_upward()
        end,
        mode = { "n" },
        desc = "Toggle Cursor Upward",
      },
      {
        "<Leader>mm",
        function()
          require("nvim-multi-cursor").toggle_cursor_at_curpos()
        end,
        mode = { "n" },
        desc = "Toggle Cursor",
      },
      {
        "<Leader>ms",
        function()
          require("nvim-multi-cursor").toggle_cursor_by_flash()
        end,
        mode = { "n" },
        desc = "Selection To Toggle Cursor",
      },
      {
        "<Leader>mw",
        function()
          require("nvim-multi-cursor").toggle_cursor_by_flash(vim.fn.expand("<cword>"))
        end,
        mode = { "n" },
        desc = "Selection Wrod To Toggle Cursor",
      },
    },
    opts = {
      hl_group = "IncSearch"
    },
  },

About

Edit with multiple cursors

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy