Hi,
Kindly help.
import sys, os, string
*SVNLOOK_PATH=os.system('which svnlook')*
def main(repos, txn):
svnlook_cmd = '%s log -t %s %s' % (*SVNLOOK_PATH*, txn, repos)
check_msg = os.popen(svnlook_cmd, 'r').readline().rstrip('\n')
if len(check_msg) 10:
sys.stderr.write
On Sat, Jan 24, 2009 at 2:03 PM, Jay Jesus Amorin jay.amo...@gmail.comwrote:
Hi,
Kindly help.
import sys, os, string
*SVNLOOK_PATH=os.system('which svnlook')*
Read the docs on os.system. It returns the program's return code, not the
child processes stdout. Use the subprocess module.
En Sat, 24 Jan 2009 17:03:33 -0200, Jay Jesus Amorin
jay.amo...@gmail.com escribió:
*SVNLOOK_PATH=os.system('which svnlook')*
You've been told what's wrong with that. But instead of fixing how to
invoke which, use distutils.spawn.find_executable instead:
py from distutils.spawn import