Running arbitrary vim commands from bash command line to script vim -
i want script vim edit files command line. example want along lines of:
vim -<some_option> 'iworld<esc>bihello <esc>:wq helloworld.txt<cr>'
or:
echo 'iworld<esc>bihello <esc>:wq helloworld.txt<cr>' | vim
and have save file helloworld.txt
body of hello world
is possible? i've tried few different approaches none seem it. realize can things vim +plugininstall
run ex commands command line, i'd love able string arbitrary motions
this can achieved +
flag , :normal
command:
$ vim +"norm iworld" +"norm ihello " +"wq helloworld.txt"
Comments
Post a Comment