Ni Va wrote: > Your command is pretty good but can I affect a variable > instead of output command under the cursor into the buffer
You have to do some work. :new :r !wmic logicaldisk get deviceid :1,2d :%s/\s\+$//e :let drives = getline(1,'$') :echo drives Select the above text and yank it (type yip). Then type :@" to execute the yanked text. The result is that a variable named drives is a list of the drive letters, for example: :echo drives ['C:', 'D:', 'E:'] John -- -- 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+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.