---
- name: '{{ notification }} | Create config directory'
  file:
    path: '{{ xdg_dir.config_home }}/{{ notification }}'
    state: directory
    mode: '755'

- name: '{{ notification }} | Create directory to store notification icons'
  file:
    path: '{{ xdg_dir.data_home }}/{{ item }}'
    state: directory
    mode: '755'
  loop:
    - icons
    - icons/notifications

- name: '{{ notification }} | Copy notification icons'
  copy:
    src: notification_icons/
    dest: '{{ xdg_dir.data_home }}/icons/notifications/'
    mode: '644'

- name: dunst | Copy config
  template:
    src: dunst/dunstrc.j2
    dest: '{{ xdg_dir.config_home }}/dunst/dunstrc'
    mode: '644'
  when: notification == 'dunst'

- name: mako | Copy config
  template:
    src: mako/config.j2
    dest: '{{ xdg_dir.config_home }}/mako/config'
    mode: '644'
  when: notification == 'mako'

- name: fnott | Copy config
  template:
    src: fnott/fnott.j2
    dest: '{{ xdg_dir.config_home }}/fnott/fnott.ini'
    mode: '644'
  when: notification == 'fnott'
