.. _bitbucket_clone_module:


bitbucket_clone -- Clone repository from Bitbucket
==================================================

.. contents::
   :local:
   :depth: 1


Synopsis
--------

Clone Bitbucket repository for provided branch



Requirements
------------
The below requirements are needed on the host that executes this module.

- pathlib
- gitpython



Parameters
----------

  username (False, str, None)
    Username used for authentication.

    This is only needed when not using *access_token*.

    Required when *url_password* is provided.


  password (False, str, None)
    Password used for authentication.

    This is only needed when not using *access_token*.

    Required when *url_username* is provided.


  access_token (False, str, None)
    Token parameter for authentication.

    This is only needed when not using *username* and *password*.


  repository (True, str, None)
    Repository name.


  project_key (True, str, None)
    Bitbucket project key.


  branch (True, str, None)
    Bitbucket branch.


  dest (False, str, None)
    Local destination directory for repository.


  force (False, boolean, False)
    Delete repository if already exists





Notes
-----

.. note::
   - Bitbucket Access Token can be obtained from Bitbucket profile -> Manage Account -> Personal Access Tokens.
   - Supports ``check_mode``.




Examples
--------

.. code-block:: yaml+jinja

    





Status
------





Authors
~~~~~~~

- Pawel Smolarz (pawel.smolarz@nordea.com)

