How to use the sarge.capture_stdout function in sarge

To help you get started, we’ve selected a few sarge examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github ManageIQ / integration_tests / rhci / scripts / View on Github external
def virsh(args):
    result = sarge.capture_stdout('virsh {}'.format(args))
    if result.returncode != 0:
        raise RuntimeError('virsh command failed with exit code {}'.format(result.returncode))
github jlesquembre / autopilot / src / autopilot / View on Github external
def stdout(command):
    return sarge.capture_stdout(command).stdout.text.strip()
github adamcharnock / dokku-client / dokku_client / commands / View on Github external
def run_remote(self, cmd, input=None):
        host = self.args['--host']
        return capture_stdout('ssh %s -- %s' % (host, cmd), input=input)


A wrapper for subprocess which provides command pipeline functionality.

Latest version published 2 years ago

Package Health Score

49 / 100
Full package analysis