On Fri, Jan 10, 2014 at 6:14 PM, Rick Dooling <rpdooling@gmail.com> wrote:
>
>
> This one grabs the buffer contents, converts it to HTML, and sends it to the clipboard for pasting into WordPress or whatever.
>
> " Send Text Through Filter To Clipboard:
> " http://vim.wikia.com/wiki/Use_filter_commands_to_process_text
> function! MDC()
> :redir @+
> " No output file specified so it goes to STDOUT
> exe '!pandoc %'
> :redir END
> endfunction
>
> This morning I was monkeying with using Python in Vim to do this. That also works. Then you can use Python's Markdown module.
>
But does it though? From what I see the line:
exe '!pandoc %'
Is running pandoc with the *file* open in the current buffer as input,
which means you have to have a file and you have to save it in order
for it to work. This is similar to what was shown in previous emails,
but what I was wondering is whether one can use something similar that
uses buffer contents, not file contents.
Regards,
--
Jacobo de Vera
http://www.jacobodevera.com
@jovianjake
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
Friday, January 10, 2014
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment