UNIX VI Editor 에서 특정 범위의 line을 정렬(sort)시키는 명령어가 있나요?
예를 들어,
B02 aaa A01 ccc
가 있으면
A01 ccc B02 aaa
로 정렬되었으면 좋겠습니다.
영역 지정 후 :!sort ----블로그 / 위키 / 리눅스 스크린샷 갤러리
----블로그 / 위키 / 리눅스 스크린샷 갤러리
V키를 눌러서 영역을 지정후에... :'<,'>sort 반대로 소트 하고 싶다면, :'<,'>sort! 이렇게 하시면 됩니다.
'<,'> ---> 이 기호는 영역 선택을 하면 기본으로 나옵니다..
텍스트 포맷에 대한 자세한 정보
<code>
<blockcode>
<apache>
<applescript>
<autoconf>
<awk>
<bash>
<c>
<cpp>
<css>
<diff>
<drupal5>
<drupal6>
<gdb>
<html>
<html5>
<java>
<javascript>
<ldif>
<lua>
<make>
<mysql>
<perl>
<perl6>
<php>
<pgsql>
<proftpd>
<python>
<reg>
<spec>
<ruby>
<foo>
[foo]
영역 지정 후
영역 지정 후 :!sort
----
블로그 / 위키 / 리눅스 스크린샷 갤러리
----
블로그 / 위키 / 리눅스 스크린샷 갤러리
영역 지정 후에..
V키를 눌러서 영역을 지정후에...
:'<,'>sort
반대로 소트 하고 싶다면,
:'<,'>sort!
이렇게 하시면 됩니다.
'<,'> ---> 이 기호는 영역 선택을 하면 기본으로 나옵니다..
댓글 달기