Skip to content

Commit 5ba907d

Browse files
committed
fix path
1 parent 90220a9 commit 5ba907d

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

autoload/vim_commands_plugin.vim

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,15 @@ function! vim_commands_plugin#openCheatSheet()
77
let l:cheat_sheet = l:user_cheat_sheet
88
else
99
" plugin directory path
10-
let l:cheat_sheet = "$HOME/.vim/plugged/vim-commands/doc/vim-commands.md"
11-
if !filereadable(l:cheat_sheet)
10+
let l:file_path = "$HOME/.vim/plugged/vim-commands/doc/vim-commands.md"
11+
12+
if filereadable(l:file_path)
13+
let l:cheat_sheet = l:file_path
14+
else
1215
let l:cheat_sheet = "$HOME/.vim/bundle/vim-commands/doc/vim-commands.md"
16+
1317
endif
18+
1419
endif
1520

1621
" Open the markdown file in a new buffer

0 commit comments

Comments
 (0)