def run_this(cmd, args, logger):
 my_cmd = (cmd % args)
 rc = subprocess_call(logger, my_cmd, shell=True)
 if (rc != 0):
  die(logger, 'Command failed')

def run_this ( cmd , args , logger ) : my_cmd = ( cmd % args ) rc = subprocess_call ( logger , my_cmd , shell = True ) if ( rc != 0 ) : die ( logger , 'Command failed' )
a simple wrapper around subprocess calls .