mirror of
https://github.com/ansible/awx.git
synced 2026-01-15 20:00:43 -03:30
Properly parse subversion revision info.
The ansible subversion module returns revision info in an unanticipated format: https://github.com/ansible/ansible/blob/devel/lib/ansible/modules/source_control/subversion.py#L194-L199 Parse out the revision number we actually care about. Resolves #4654
This commit is contained in:
parent
8625d670ac
commit
9e09fd38a7
@ -115,6 +115,12 @@
|
||||
chdir: "{{project_path|quote}}/roles"
|
||||
when: doesRequirementsExist.stat.exists and scm_full_checkout|bool
|
||||
|
||||
# format provided by ansible is ["Revision: 12345", "URL: ..."]
|
||||
- name: parse subversion version string properly
|
||||
set_fact:
|
||||
scm_version: "{{scm_version|regex_replace('^.*Revision: ([0-9]+).*$', '\\1')}}"
|
||||
when: scm_type == 'svn'
|
||||
|
||||
- name: Repository Version
|
||||
debug: msg="Repository Version {{ scm_version }}"
|
||||
when: scm_version is defined
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user