hidden - Hide echo from apt-get in python -
how can hide process of installing java (apt-get openjdk-6-jre) when it's runned in python? can replace "installing java..." till it's ready.
thanks in advance.
here's implementation of @khachik's comment:
import os subprocess import stdout, check_call check_call(['apt-get', 'install', 'openjdk-6-jre'], stdout=open(os.devnull,'wb'), stderr=stdout) it raises exception in case of error.
Comments
Post a Comment