Only apply K3s autocomplete when ansible_user is defined (#398)

Signed-off-by: Derek Nola <derek.nola@suse.com>
pull/402/head
Derek Nola 2025-03-20 10:49:03 -07:00 committed by GitHub
parent 8f71b09a4c
commit c38327927b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 0 deletions

View File

@ -35,6 +35,7 @@
changed_when: true
- name: Add K3s autocomplete to user bashrc
when: ansible_user is defined
ansible.builtin.lineinfile:
path: "~{{ ansible_user }}/.bashrc"
regexp: '\.\s+<\(k3s completion bash\)'