iamcco / markdown-preview.nvim

markdown preview plugin for (neo)vim
MIT License
6.82k stars 284 forks source link

fix: image path issue with msys2/vim #604

Closed zhenggennj closed 1 year ago

zhenggennj commented 1 year ago

1) Issue background a) on 'mingw32' terminal b) executable 'vim' in /usr/bin c) executable 'node' in /mingw32/bin. d) plugin 'markdow-preview.nvim' in ~/.vim/plugged e) app/route.js:68 fileDir is a unix path f) image missing in browser preview 2) Issue fixing add code to app/route.js: a) extract info from environment variable MINGW_HOME b) prefixing imgPath with sth. like "E:\msys64\" 3) No issue alternative a) on 'ucrt64' terminal b) executable 'nvim' in /ucrt64/bin c) executable 'node' in /ucrt64/bin d) plugin 'markdown-preview.nvim' in ~/.vim/plugged e) app/route.js:68 fileDir is a win path f) image ok in browser preview