/registers.xplr

Use multiple registers to store the selected paths

Primary LanguageLuaMIT LicenseMIT

registers.xplr

Use multiple registers to store the selected paths.

Usage example

  • Select paths usinhg space .
  • Type " a to put the selection into a register.
  • Select some more paths.
  • Type " a again to swap the selection with a register's content.
  • Press ctrl-u to unselect all.
  • Type " a to move the selection from a register to the selection list.

Requirements

none

Installation

Install using xpm.xplr

require("xpm").setup({
  { name = 'sayanarijit/registers.xplr' },
})

Install manually

  • Add the following line in ~/.config/xplr/init.lua

    local home = os.getenv("HOME")
    package.path = home
      .. "/.config/xplr/plugins/?/src/init.lua;"
      .. home
      .. "/.config/xplr/plugins/?.lua;"
      .. package.path
  • Clone the plugin

    mkdir -p ~/.config/xplr/plugins
    
    git clone https://github.com/sayanarijit/registers.xplr ~/.config/xplr/plugins/registers
  • Require the module in ~/.config/xplr/init.lua

    require("registers").setup()
    
    -- Or
    
    require("registers").setup{
      mode = "default",
      key = '"',
    }
    
    -- Type `"` and then another character to swap the selection with a register.

Features

  • Swap the current selection with any register.
  • See the active registers with selection count.

Todo

  • Global registers
  • Clipboard support