def rmtree (self, errors='warn'):
        """Recursively delete this directory and its contents. The *errors* keyword
        specifies how errors are handled:

        "warn" (the default)
          Print a warning to standard error.
        "ignore"
          Ignore errors.

        """
        import shutil

        if errors == 'ignore':
            ignore_errors = True
            onerror = None
        elif errors == 'warn':
            ignore_errors = False
            from .cli import warn

            def onerror (func, path, exc_info):
                warn ('couldn\'t rmtree %s: in %s of %s: %s', self, func.__name__,
                      path, exc_info[1])
        else:
            raise ValueError ('unexpected "errors" keyword %r' % (errors,))

        shutil.rmtree (text_type (self), ignore_errors=ignore_errors, onerror=onerror)
        return self