blob: ef402e51f207862d0f5dacfa9794ba01ac20c1f0 [file] [log] [blame]
---
- name: Install completion for the bash shell
package:
name: "{{ completion_package }}"
state: present
- name: Ensure bash completion dir exists
file:
path: "{{ completion_dir }}"
state: directory
mode: 0755
- name: Generate shell autocompletion code for {{ completion_bin }}
command: "{{ completion_bin }} completion bash"
register: bash_completion
changed_when: false
- name: Install bash autocompletion code for {{ completion_bin }}
copy:
content: "{{ bash_completion.stdout }}"
dest: "{{ completion_dir }}/{{ completion_bin }}"
mode: 0644