Allow refspec in role fetcher

This allows specification in the ansible-role-requirements to pull
a role directly from a gerrit change.

Example:
- name: os_neutron
  scm: git
  src: https://git.openstack.org/openstack/openstack-ansible-os_neutron
  version: FETCH_HEAD
  refspec: '+refs/changes/24/391524/*:refs/remotes/origin/changes/24/391524/*'

This will pull the latest revision of change 391524.

Change-Id: I96666f349d6f0317d51735146e94c3bd12c7ef6f
This commit is contained in:
Logan V
2016-12-05 14:25:35 -06:00
parent ab44138d0f
commit 303706708c

View File

@@ -33,6 +33,7 @@
repo: "{{ item.src }}"
dest: "{{ item.path | default(role_path_default) }}/{{ item.name | default(item.src | basename) }}"
version: "{{ item.version | default('master') }}"
refspec: "{{ item.refspec | default(omit) }}"
update: true
force: true
when: