안녕하세요
현재 프로그램하나를 돌리는데 시간이 좀 오래걸리고 결과물도 많아서 python xxx.py > result로 저장하는데요. 하지만 저렇게 하면 결과자료는 result로 저장이되지만 문제는 실시간으로 프로그램의 출력물을 확인할수가 없어서 답답하더군요. 파일로 출력을 저장하면서 동시에 보는 방법은 없을까요?
(애초 프로그램 코딩할때 파일에 저장시키면서 출력하게 하면 되겠지만 궁금합니다)
좋은하루 되세요
python xxx.py > result ; more result
얘는 실시간 조건을 충족하지 못하는군요.
python xxx.py | tee result
man script
세벌 https://sebuls.blogspot.kr/
python xxx.py > result tail -f result
실시간 조건 때문에...
python xxx.py > result & tail -f result
python xxx.py > result &; tail -f result
요렇게 되어야 할 듯.
man tee
라서 쓰고보니 어느 분이 벌써 올리셨군요. tee 가 정답입니다.
텍스트 포맷에 대한 자세한 정보
<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]
python xxx.py > result ; more
python xxx.py > result ; more result
얘는 실시간 조건을 충족하지 못하는군요.
얘는 실시간 조건을 충족하지 못하는군요.
man tee
python xxx.py | tee result
man script
man script
세벌 https://sebuls.blogspot.kr/
tail
python xxx.py > result
tail -f result
실시간 조건 때문에... python xxx.py
실시간 조건 때문에...
python xxx.py > result &
tail -f result
python xxx.py > result &; tail -f result
요렇게 되어야 할 듯.
man tee python xxx.py | tee
man tee
python xxx.py | tee result
라서 쓰고보니 어느 분이 벌써 올리셨군요. tee 가 정답입니다.
댓글 달기