20220305

Open PDF files in vim-nox under Crostini (Chromebook/ChromeOs Debian)

Method 1 - good for VimWiki or plain text Zettelkasten using pdftotext (pdf -> txt)

Procedure
Put one of the following mappings in your vimrc:

:command! -complete=file -nargs=1 Rpdf :r !pdftotext -nopgbrk <q-args> -

Run with 
:tabnew
:Rpdf example.pdf

Method 2 use chrome browser as default application but has side effect of error
Run :term 
$ xdg-open ./<filename>.pdf

No comments:

Post a Comment