# drone plugin example For example, this implements a complex custom clone step (involving merging and pushing to a remote repository): ``` - name: clone image: kaspar030/drone-clone settings: SSH_KEY: from_secret: ssh_key_clone mode: clone base_repo: ${DRONE_REPO_LINK} base_branch: ${DRONE_REPO_BRANCH} build_repo: ${DRONE_GIT_HTTP_URL} build_branch: ${DRONE_SOURCE_BRANCH} build_commit: ${CI_COMMIT_SHA} merge_commit_repo: riot-ci/RIOT ``` The "guts" of this are ~140 lines of package installation, git magic, error handling: ``` riot-drone/drone-clone on  master ❯ ls -la total 8 drwxr-xr-x 2 kaspar kaspar 41 16. Dez 11:14 . drwxr-xr-x 6 kaspar kaspar 69 15. Dez 23:35 .. -rw-r--r-- 1 kaspar kaspar 448 15. Dez 23:20 Dockerfile -rwxr-xr-x 1 kaspar kaspar 3569 16. Dez 11:14 script.sh riot-drone/drone-clone on  master ❯ cat Dockerfile script.sh | wc -l 139 ``` - [script.sh](https://gist.github.com/f4fe50cd9dc936abd465b9cb4e5b8084) - [Dockerfile](https://gist.github.com/3d937f35084fd132832a825330d4dba2) `