[问题] 要如何显示出shell script内的log

楼主: ghost108 (Rick-Zeng)   2017-09-22 17:17:09
手机排版很伤眼睛
各位程式高手,小弟初学者
目前遇到瓶颈
想用试试看在python下执行shell script
然后show出此shell script的执行log ,一行一行列出
使用过subprocess.popen
communicate, stdout
发现都是最后执行shell script完毕后才出现
想要的内容
因为我不想在背景下看不到执行过程
tkinter接口会出现“没有回应“
所以想要找个办法去解
作者: neil987 (R5大小姐-EX人品崩坏)   2017-09-22 23:15:00
我的做法是 myscript.py > temp.txt read temp del temp查了一下 应该是这个 https://goo.gl/2nJQGv

Links booklink

Contact Us: admin [ a t ] ucptt.com