GithubHelp home page GithubHelp logo

slimux.nvim's People

Contributors

evwilson avatar zahimeen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

slimux.nvim's Issues

Error sending visual selection to tmux (vim.send_highlighted_text)

Thanks for a great and useful plugin.

I'm getting the following error when attempting to send a visual selection to a tmux pane:

E5108: Error executing lua: ...a/.local/share/nvim/lazy/slimux.nvim/lua/slimux/init.lua:98: b
ad argument #1 to 'gsub' (string expected, got nil)                                          
stack traceback:                                                                             
        [C]: in function 'gsub'                                                              
        ...a/.local/share/nvim/lazy/slimux.nvim/lua/slimux/init.lua:98: in function 'escape' 
        ...a/.local/share/nvim/lazy/slimux.nvim/lua/slimux/init.lua:139: in function 'send'  
        ...a/.local/share/nvim/lazy/slimux.nvim/lua/slimux/init.lua:153: in function <...a/.l
ocal/share/nvim/lazy/slimux.nvim/lua/slimux/init.lua:151>                                    
"Whiteboard.txt" 280L, 10089B 

I'm use LazyVim and my slimux.nvim config is:

  {
    "EvWilson/slimux.nvim",
    config = function()
      local slimux = require("slimux")
      slimux.setup({
        target_socket = slimux.get_tmux_socket(),
        target_pane = string.format("%s.2", slimux.get_tmux_window()),
      })
      vim.keymap.set(
        "v",
        "<leader>r",
        slimux.send_highlighted_text,
        { desc = "Send currently highlighted text to configured tmux pane" }
      )
      vim.keymap.set(
        "n",
        "<leader>r",
        slimux.send_paragraph_text,
        { desc = "Send paragraph under cursor to configured tmux pane" }
      )
    end,
  },

I don't get any errors when sending paragraphs, only visual selections.

My version of Neovim is NVIM v0.11.0-dev-482+g7381f0a1d5

Hope this is useful!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.