How to execute ‘base64 --decode’ on selected text in Vim?

后端 未结 5 2033
北恋
北恋 2021-02-06 23:58

I’m trying to execute base64 --decode on a piece of text selected in Visual mode, but it is the entire line that seems to be passed to the base64 comma

5条回答
  •  死守一世寂寞
    2021-02-07 00:48

    If you want to replace the text with the output of base64, use something like

    :vnoremap 64 y:let @"=system('base64 --decode', @")gvP
    

提交回复
热议问题