Files
ansible-role-oh-my-zsh/tasks/zsh-zshrc.yml
2025-01-09 16:02:22 +01:00

15 lines
509 B
YAML

---
# Note that we assume this file exists! lineinfile will fail if the file is
# not present.
- name: "OMZ | export vars to .zshrc if required."
blockinfile:
dest: "{{ omz_user_zshrc_path }}"
block: "{{ omz_user.settings }}"
backup: "{{ omz_zshrc_backup }}"
when:
- "omz_user.settings is defined"
# Don't flag this line for checking if the value is empty--checking for an
# empty value makes perfect sense.
- "omz_user.settings != ''" # noqa 602
- "not omz_zshrc_create"