Skip to content

domsch1988/mattern.nvim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Mattern

Custom Line Marks based on Pattern matching

Screenshot

📦 Installation

Install the plugin with your preferred package manager:

return {
    'domsch1988/mattern.nvim',
    config = function()
        require('mattern').setup({
            markers = {
                { 'asgard:', 'Matched ASGARD', "@comment.error", "yaml" },
            }
        })
    end
}

Setup

Mattern comes with the following defaults:

{
    position = "eol",   -- Where the marks should be displayed: "eol", "overlay", "right_align", "inline"
    hl_mode = "blend",  -- How the Highlightgroup should be applied: "replace", "combine", "blend"
    markers = {         -- A list of your Rules
        -- Our Custom Marker Definitions
        -- | Pattern      | Text to Write   | HL Group        | Optional Filetype |
        { 'mattern', 'A default for Testing', "@comment.error", "lua" },
    }
}

🚀 Usage

Mattern sets up a Autocommand for BufEnter and BufWinEnter by default. The function require('mattern').mattern_print() can be used to set up your own Autocommands or Keybinds

About

Custom Pattern base Marks for NeoVIM

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors