我有以下代码:
pwd = '/home/user/svnexport/Repo/'
updateSVN = "svn up " + pwd
cmd = os.popen(updateSVN)
getAllInfo = "svn info " + pwd + "branches/* " + pwd + "tags/* " + pwd + "trunk/*"
cmd = os.popen(getAllInfo)
如何确保cmd = os.popen(updateSVN)
在cmd = os.popen(getAllInfo)
开始执行之前已完成执行?在
如果您需要第一个命令终止,那么实际上并不需要多线程。你能做到的
如果您真的想使用updateSVN,可以通过
^{pr2}$尝试wait()方法:
您应该使用
subprocess
:如果您需要捕获子进程的输出,那么应该这样做
^{pr2}$相关问题 更多 >
编程相关推荐