[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 594
  • Last Modified:

vim command to alphabetize lines in a file

I'm looking for a vim command that will alphabetize the lines in a file. That is:

pear
apple
orange


..would change to..

apple
pear
orange
0
zumpoof
Asked:
zumpoof
1 Solution
 
arnoldCommented:
0
 
AnuroopsunddCommented:
vim :%!sort
0

Featured Post

Receive 1:1 tech help

Solve your biggest tech problems alongside global tech experts with 1:1 help.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now