~pexego/openobject-addons/6.1-pexego-sale_commission

« back to all changes in this revision

Viewing changes to pexego-runbot/pxgorunbot/misc.py

  • Committer: Santi Argueso (Pexego)
  • Date: 2013-02-06 17:03:36 UTC
  • mfrom: (10.1.6 pexego-addons_6.1)
  • Revision ID: santiago@pexego.es-20130206170336-ml430s6p9jknun0j
[MERGE]

Show diffs side-by-side

added added

removed removed

Lines of Context:
29
29
            i=repr(i)
30
30
        out.append(i)
31
31
    out+=["%s=%r"%(k,v) for k,v in kw.items()]
 
32
    print "LOG: ", out
32
33
    with log_lock:
33
34
        print " ".join(out)
34
35
 
41
42
 
42
43
def run(l,env=None):
43
44
    log("run",l)
44
 
    print "TYPE: ", type(l)
45
45
    env = dict(os.environ, **env) if env else None
46
46
    if isinstance(l,list):
47
47
        if env:
64
64
        pass
65
65
 
66
66
def run_output(l, cwd=None):
67
 
    print "CMD: ", l
68
67
    return subprocess.Popen(l, cwd=cwd).communicate()[0]
69
68
 
70
69
def run_and_get(l, env=None):