Sort

❌이전글/이전글

sort정렬 명령어와 리다이렉션 활용

1 2 3 4 5 6 7 8 9 10 11 12 [root@localhost ~]# cat test.txt b a c g h t e f ds f n 리눅스 터미널창 커맨드라인에서 cat명령어로 출력했을 때 위와 같이 text파일이 있다고 가정하자. 정렬이 필요할 때 sort 와 리다이렉션을 같이 써주면 정렬된 값으로 출력될 수 있다. 1 2 3 4 5 6 7 8 9 10 11 12 [root@localhost ~]# sort 리다이렉션 하나 더 사용해주면된다. 1 2 3 4 5 6 7 8 9 10 11 12 13 [root@localhost ~]$ sort Sort.txt [root@localhost ~]$ cat Sort.txt a b c ds e f f g h n t

부드러운당근무침
'Sort' 태그의 글 목록