Reputation: 5553
I have a document like such:
asdf
asdf
asdf
asdf
asdf
asdf
asdf
asdf
I want to convert this into the following or something more readable with -, ==, *, etc... depending on 4*n spaces (tab == 4 spaces in my vim)
- asdf
- asdf
- asdf
- asdf
- asdf
- asdf
- asdf
- asdf
Upvotes: 2
Views: 35
Reputation: 15330
This should do it:
:%s/[^ ]/- &/
Replace the first non space character with -
and the character.
Upvotes: 1