Saturday, January 22, 2011

Re: Exchange word separated by =

It's simple. Try use something like:
:%s/\(.*\)=\(.*\)/\2=\1

Karol

2011/1/22 Matthias Guenther <lordmatze@googlemail.com>:
> I have the following text structure:
>
> Abstoß               = goal-kick
> Antriebslosigkeit  = listlessness
> Bettlacken           = bed sheet
> Eierstöcke           = ovaries
> ...
>
> Is it possible to use a command (or a plugin) which just exchange the
> content on each row separated by the = sign. In the end I would like
> to have the following structure:
>
>
> goal-kick               = Abstoß
> listlessness  = Antriebslosigkeit
> bed sheet           = Bettlacken
> ovaries           = Eierstöcke
> ...
>
> Thanks for your help.
> Matthias
>
> --
> 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 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

No comments: