2016-03-14 17:57:40 +08:00
|
|
|
---
|
|
|
|
- name: check if there is python
|
|
|
|
raw: stat $HOME/.python
|
|
|
|
register: need_python
|
|
|
|
ignore_errors: true
|
2017-10-25 22:53:34 +08:00
|
|
|
check_mode: no
|
2016-03-14 17:57:40 +08:00
|
|
|
|
2018-08-21 22:23:35 +08:00
|
|
|
- include_tasks: install_pypy.yml
|
2016-03-14 17:57:40 +08:00
|
|
|
when: need_python | failed
|
|
|
|
|
|
|
|
- name: check if there is pip
|
|
|
|
raw: stat $HOME/.pip
|
|
|
|
register: need_pip
|
|
|
|
ignore_errors: true
|
2017-10-25 22:53:34 +08:00
|
|
|
check_mode: no
|
2016-03-14 17:57:40 +08:00
|
|
|
|
2018-08-21 22:23:35 +08:00
|
|
|
- include_tasks: install_pip.yml
|
2016-09-10 06:16:41 +08:00
|
|
|
when: need_pip | failed and need_python | failed
|