# ansible-galaxy keep clone of role

**URL:** <https://forum.ansible.com/t/ansible-galaxy-keep-clone-of-role/26426>\
**Category:** Ansible Developer\
**Tags:** galaxy-ng\
**Created:** [January 5, 2018, 6:15pm UTC](https://forum.ansible.com/t/ansible-galaxy-keep-clone-of-role/26426 "2018-01-05T18:15:12Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Spencer\_Jensen](https://avatars.discourse-cdn.com/v4/letter/s/59ef9b/32.png) [@Spencer\_Jensen](https://forum.ansible.com/u/Spencer_Jensen)\
**Post date:** [January 5, 2018, 6:15pm UTC](https://forum.ansible.com/t/ansible-galaxy-keep-clone-of-role/26426/1 "2018-01-05T18:15:12Z")

</div>

In reference to this issue: [https://github.com/ansible/ansible/issues/12353](https://github.com/ansible/ansible/issues/12353)

I’ve come across the need to be able to “clone” a private role using ansible-galaxy and the requirements.yml file and found the above issue on this topic. It doesn’t appear anyone was planning to implement this so I forked the repo and made the changes. I’ve got everything working but wasn’t sure if I should submit a pull request or if there were other things to consider first.

you can find my code here: [https://github.com/spencerwjensen/ansible/tree/galaxy-clone](https://github.com/spencerwjensen/ansible/tree/galaxy-clone)

thanks  
spencer

---

<div class="post-metadata">

**Author:** ![ljenkin](https://avatars.discourse-cdn.com/v4/letter/l/cc9497/32.png) [@ljenkin](https://forum.ansible.com/u/ljenkin)\
**Post date:** [January 7, 2018, 6:02am UTC](https://forum.ansible.com/t/ansible-galaxy-keep-clone-of-role/26426/2 "2018-01-07T06:02:30Z")

</div>

Hi Spencer,

I have also been looking at the same thing, [https://github.com/leigh-j/ansible/tree/galaxy-clone](https://github.com/leigh-j/ansible/tree/galaxy-clone)

From reading a few other proposals I think the ansible devs don’t want to make these sort of changes to the requirements definition, I am working on something similar that is done via command line options rather than role definitions. I think it’s the sort of thing that belongs as a command line option in the same vain as role path and no-deps Though I can see how this would be useful for cloning just some roles.

I got sidetracked with christmas but will put up a proposal today if I can
