def git_commit(*args, fn=cmd_output, msg='commit!', all_files=True, **kwargs):
    kwargs.setdefault('stderr', subprocess.STDOUT)
    cmd = ('git', 'commit', '--allow-empty', '--no-gpg-sign', *args)
    if all_files:
        cmd += ('-a',)
    if (msg is not None):
        cmd += ('-m', msg)
    (ret, out, _) = fn(*cmd, **kwargs)
    return (ret, out.replace('\r\n', '\n'))
def git_commit(*args, fn=cmd_output, msg='commit!', all_files=True, **kwargs):
    kwargs.setdefault('stderr', subprocess.STDOUT)
    cmd = ('git', 'commit', '--allow-empty', '--no-gpg-sign', *args)
    if all_files:
        cmd += ('-a',)
    if (msg is not None):
        cmd += ('-m', msg)
    (ret, out, _) = fn(*cmd, **kwargs)
    return (ret, out.replace('\r\n', '\n'))