Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add g:minimap_exec_warning to control code-minimap not found message #181

Merged
merged 1 commit into from
Jul 24, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ let g:minimap_auto_start_win_enter = 1
| `g:minimap_block_buftypes` | `['nofile', 'nowrite', 'quickfix', 'terminal', 'prompt']` | disable minimap for specific buffer types |
| `g:minimap_close_filetypes` | `['startify', 'netrw', 'vim-plug']` | close minimap for specific file types |
| `g:minimap_close_buftypes` | `[]` | close minimap for specific buffer types |
| `g:minimap_exec_warning` | `1` | if set, enables code-minimap not found warning message at startup |
| `g:minimap_left` | `0` | if set, minimap window will append left |
| `g:minimap_highlight_range` | `1` | if set, minimap will highlight range of visible lines |
| `g:minimap_highlight_search` | `0` | if set, minimap will highlight searched patterns |
Expand Down
7 changes: 7 additions & 0 deletions doc/minimap-vim.txt
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,13 @@ g:minimap_close_buftypes *g:minimap_close_buftypes*
present in `g:minimap_block_buftypes`, the minimap will prefer to close
rather than disable.

g:minimap_exec_warning *g:minimap_exec_warning*

Type: |Number|
Default: `1`

If set to 1, enables code-minimap not found warning message at startup.

g:minimap_highlight_search *g:minimap_highlight_search*

Type: |Number|
Expand Down
9 changes: 8 additions & 1 deletion plugin/minimap.vim
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,15 @@ if v:version < 800
finish
endif

if !exists('g:minimap_exec_warning')
let g:minimap_exec_warning = 1
endif

if !executable('code-minimap')
echom 'minimap: this plugin requires code-minimap installed.'
if g:minimap_exec_warning != 0
echom 'minimap: this plugin requires code-minimap installed.'
endif

finish
endif

Expand Down
Loading