|
17 | 17 | * [Plugin Spec](#plugin-spec)
|
18 | 18 | * [Commands](#commands)
|
19 | 19 | * [Default UI](#default-ui)
|
| 20 | +* [Notify UI](#notify-ui) |
20 | 21 | * [Custom Plugin UI](#custom-plugin-ui)
|
21 | 22 | * [Plugin priority](#plugin-priority)
|
22 | 23 | * [Feedback](#feedback)
|
@@ -219,6 +220,73 @@ vim.cmd('hi def link PlugFailed WarningMsg')
|
219 | 220 | vim.cmd('hi def link PlugDoing Number')
|
220 | 221 | ```
|
221 | 222 |
|
| 223 | +## Notify UI |
| 224 | + |
| 225 | +You can also change the ui to `notify`: |
| 226 | + |
| 227 | + |
| 228 | + |
| 229 | +This UI is based on [notify.nvim](https://github.com/wsdjeg/notify.nvim). So you need to install it before using nvim-plug: |
| 230 | + |
| 231 | +```lua |
| 232 | +if vim.fn.isdirectory('D:/bundle_dir/wsdjeg/nvim-plug') == 0 then |
| 233 | + vim.fn.system({ |
| 234 | + 'git', |
| 235 | + 'clone', |
| 236 | + '--depth', |
| 237 | + '1', |
| 238 | + 'https://github.com/wsdjeg/nvim-plug.git', |
| 239 | + 'D:/bundle_dir/wsdjeg/nvim-plug', |
| 240 | + }) |
| 241 | +end |
| 242 | +vim.opt.runtimepath:append('D:/bundle_dir/wsdjeg/nvim-plug') |
| 243 | +if vim.fn.isdirectory('D:/bundle_dir/wsdjeg/notify.nvim') == 0 then |
| 244 | + vim.fn.system({ |
| 245 | + 'git', |
| 246 | + 'clone', |
| 247 | + '--depth', |
| 248 | + '1', |
| 249 | + 'https://github.com/wsdjeg/notify.nvim.git', |
| 250 | + 'D:/bundle_dir/wsdjeg/notify.nvim', |
| 251 | + }) |
| 252 | +end |
| 253 | +vim.opt.runtimepath:append('D:/bundle_dir/wsdjeg/notify.nvim') |
| 254 | + |
| 255 | +require('plug').setup({ |
| 256 | + |
| 257 | + bundle_dir = 'D:/bundle_dir', |
| 258 | + raw_plugin_dir = 'D:/bundle_dir/raw_plugin', |
| 259 | + ui = 'notify', |
| 260 | + http_proxy = 'http://127.0.0.1:7890', |
| 261 | + https_proxy = 'http://127.0.0.1:7890', |
| 262 | + enable_priority = true, |
| 263 | + max_processes = 16, |
| 264 | +}) |
| 265 | + |
| 266 | +require('plug').add({ |
| 267 | + { |
| 268 | + 'wsdjeg/logger.nvim', |
| 269 | + config = function() |
| 270 | + require('logger').setup({ level = 0 }) |
| 271 | + vim.keymap.set( |
| 272 | + 'n', |
| 273 | + '<leader>hL', |
| 274 | + '<cmd>lua require("logger").viewRuntimeLog()<cr>', |
| 275 | + { silent = true } |
| 276 | + ) |
| 277 | + end, |
| 278 | + }, |
| 279 | + { |
| 280 | + 'wsdjeg/notify.nvim', |
| 281 | + fetch = true, |
| 282 | + }, |
| 283 | + { |
| 284 | + 'wsdjeg/nvim-plug', |
| 285 | + fetch = true, |
| 286 | + }, |
| 287 | +}) |
| 288 | +``` |
| 289 | + |
222 | 290 | ## Custom Plugin UI
|
223 | 291 |
|
224 | 292 | To setup custom UI, you need to creat a on_update function, this function is called with two arges, `name` and `plugUiData`.
|
|
0 commit comments