[명령] tee : stdin을 입력받아 stdout, file에 write

markyang92·2021년 8월 29일
0

linux (ubuntu/debian)

목록 보기
25/37
post-thumbnail

tee

  • tee 명령은
    • 입력: STDIN
    • 출력: STDOUT, file_IO

기존 >>pipe 단점

$ ls -al >> file.txt
$ ls -al | awk '{print($1)}'

  • 기존 redirect는 file에 write하긴하나.. 사용자에게 출력을 안보여주는 단점

tee: redirect + stdout출력

tee : > + 화면 표시

$ ls -al > file.txt
$ ls -al | tee file.txt


tee -a : >> + 화면 표시

$ ls -al >> file.txt
$ ls -al | tee -a file.txt

profile
pllpokko@alumni.kaist.ac.kr

0개의 댓글