Vim 删除空行、行首空格、行尾空格

May 12, 2021

  • 删除空格行:
:g/^$/d
  • 删除所有行首空格:
:%s/^\s*//g
  • 删除所有行尾空格:
:%s/\s*$//g

Copyright © Arcto 2022, Built with Gatsby