GithubHelp home page GithubHelp logo

williamboman / notifier.nvim Goto Github PK

View Code? Open in Web Editor NEW

This project forked from vigoux/notifier.nvim

1.0 1.0 0.0 118 KB

Non-intrusive notification system for neovim

License: BSD 3-Clause "New" or "Revised" License

Lua 97.79% Nix 1.38% Makefile 0.84%

notifier.nvim's Introduction

notifier.nvim non-intrusive notification system for neovim

Showcase

Setup

Using packer.nvim:

use {
  "vigoux/notifier.nvim",
  config = function()
    require'notifier'.setup {
    -- You configuration here
    }
  end
}

The default configuration is:

{
  ignore_messages = {}, -- Ignore message from LSP servers with this name
  status_width = something, -- COmputed using 'columns' and 'textwidth'
  components = {  -- Order of the components to draw from top to bottom (first nvim notifications, then lsp)
    "nvim",  -- Nvim notifications (vim.notify and such)
    "lsp"  -- LSP status updates
  },
  notify = {
    clear_time = 5000, -- Time in milisecond before removing a vim.notifiy notification, 0 to make them sticky
    min_level = vim.log.level.INFO, -- Minimum log level to print the notification
  },
  component_name_recall = false -- Whether to prefix the title of the notification by the component name
}

This plugin provides some commands:

:NotifierClear   " Clear the vim.notify items
:NotifierReplay  " Replay all vim.notify items

This plugin defines multiple highlight groups that you can configure:

  • NotifierTitle: the title of the notification (lsp:.. and nvim)
  • NotifierIcon: Icon of the notification (if any)
  • NotifierContent: the content of the notification
  • NotifierContentDim: dimmed content of the notification

vim.notify options

This plugin supports two options for vim.notify:

title: string -- The title for this notification
icons: string -- The icon for this notification, must be of display width 1 (see strdisplaywidth())

Acknoledgement

Heavily inspired by fidget.nvim

TODO

  • Handle LSP progress
  • Hook into vim.notify and friends
    • Allow to customize log levels
  • When out, hook into ui_attach to route more messages from nvim
  • Add docs for status.push and status.pop

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.