'Resets the index and working tree to head.
Discards any changes to tracked files in the working
tree since that commit.'

def reset(self, force):

    if ((not force) and self.has_local_mods()):
        self.module.fail_json(msg='Local    modifications    exist    in    branch    (force=no).')
    return self._command(['revert'], check_rc=True, cwd=self.dest)
