mirror of
https://github.com/HanXHX/ansible-php.git
synced 2026-03-16 11:02:10 +07:00
Better way to get php version
This commit is contained in:
@@ -20,7 +20,7 @@
|
|||||||
when: php_install_xdebug
|
when: php_install_xdebug
|
||||||
|
|
||||||
- name: SHELL | Get PHP version on apt
|
- name: SHELL | Get PHP version on apt
|
||||||
shell: LANG=C apt-cache policy php5 2>&1 | awk '/Candidate:/ { print $2 }'
|
shell: php -v | head -n 1 | awk '{ print $2 }'
|
||||||
register: php_apt_version
|
register: php_apt_version
|
||||||
changed_when: false
|
changed_when: false
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user