"""
bootstrapping debian functions for for dmm.
"""

from command_runner import command_runner

def debootstrap(destination, release, mirror, debootstrapopts):
    """
    Use debootstrap to bootstrap a Debian system.
    """
    ecode, result = command_runner("debootstrap %s %s %s %s" % (debootstrapopts,
                                                    release,
                                                    destination,
                                                    mirror))
    return ecode, result


def mmdebstrap(destination, release, mirror, debootstrapopts):
    """
    Use mmdebstrap to bootstrap a Debian system.
    """
    print("mmdebstrap %s %s" % (release, destination))
    ecode, result = command_runner("mmdebstrap %s %s" % (release, destination))
    return ecode, result

