Skip to content

rbmarliere/get_maintainer.nvim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

This is a simple wrapper around get_maintainer.pl

Installation

return {
  "rbmarliere/get_maintainer.nvim",
  opts = {
    -- path = "/somewhere/get_maintainer.pl" -- defaults to get_maintainer.pl, assume it's visible in $PATH
    -- use_clipboard = "" -- can be unnamed or unnamedplus, where to send the script output
    -- args = {
    --   "--flags-to-the-script", -- defaults to {"--scm"} to retrieve the trees too
    -- },
  },
  config = function(_, opts)
    local get_maintainer = require("get_maintainer")
    get_maintainer.setup(opts)

    -- suggested mappings
    vim.keymap.set("n", "<Leader>M", get_maintainer.get_from_file, { noremap = true })
    vim.api.nvim_create_autocmd("FileType", {
      pattern = { "fugitive" },
      callback = function()
        vim.keymap.set("n", "<Leader>M", get_maintainer.get_from_cursor, { noremap = true, buffer = true })
        vim.keymap.set("x", "<Leader>M", get_maintainer.get_from_range, { noremap = true, buffer = true })
      end,
    })
  end,
}

About

Simple wrapper for Linux' get_maintainer.pl

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages