-
-
Notifications
You must be signed in to change notification settings - Fork 4
/
bookmark.lua
38 lines (33 loc) · 1.22 KB
/
bookmark.lua
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
local M = { --
'MattesGroeger/vim-bookmarks',
id = 'bookmark',
desc = 'bookmark',
}
M.highlights = {
BookmarkSign = { ctermbg = 234, ctermfg = 27 },
BookmarkLine = { ctermbg = 'NONE', ctermfg = 'NONE' },
BookmarkAnnotationSign = { ctermbg = 234, ctermfg = 35 },
BookmarkAnnotationLine = { ctermbg = 'NONE', ctermfg = 'NONE' },
}
M.keymaps = {
{ 'n', '<Leader>bb', '<Plug>BookmarkToggle' },
{ 'n', '<Leader>ba', '<Plug>BookmarkAnnotate' },
{ 'n', '<Leader>bs', '<Plug>BookmarkShowAll' },
{ 'n', '<Leader>bl', '<Plug>BookmarkShowAll' },
{ 'n', '<Leader>bj', '<Plug>BookmarkNext<CR>k<Leader>b' },
{ 'n', '<Leader>bk', '<Plug>BookmarkPrev<CR>k<Leader>b' },
{ 'n', '<Leader>bc', '<Plug>BookmarkClear<CR>' },
{ 'n', '<Leader>bC', '<Plug>BookmarkClearAll' },
{ 'n', '<Leader>bK', '<Plug>BookmarkMoveUp<CR>k<Leader>b' },
{ 'n', '<Leader>bJ', '<Plug>BookmarkMoveDown<CR>k<Leader>b' },
{ 'n', '<Leader>bt', '<Plug>BookmarkMoveToLine' },
}
function M.config(config)
local symbolMap = config.symbolMap
vim.g.bookmark_no_default_key_mappings = 1
vim.g.bookmark_sign = symbolMap.BOOKMARK
vim.g.bookmark_annotation_sign = symbolMap.BOOKMARK_ANNOTATION
vim.g.bookmark_highlight_lines = 1
vim.g.bookmark_location_list = 1
end
return M