2020-03-11 20:51:00 +01:00
|
|
|
---
|
2020-03-11 21:08:00 +01:00
|
|
|
- name: create weechat directory
|
|
|
|
become: true
|
|
|
|
file:
|
2021-05-27 16:18:04 +02:00
|
|
|
path: "{{ weechat__home_directory }}/.weechat"
|
2020-03-11 21:08:00 +01:00
|
|
|
state: directory
|
2021-05-27 16:18:04 +02:00
|
|
|
owner: "{{ weechat__user }}"
|
2020-03-11 21:08:00 +01:00
|
|
|
mode: "0750"
|
|
|
|
|
|
|
|
- name: create weechat plugins directory
|
|
|
|
become: true
|
|
|
|
file:
|
2021-05-27 16:18:04 +02:00
|
|
|
path: "{{ weechat__home_directory }}/.weechat/{{ item.value }}/autoload"
|
2020-03-11 21:08:00 +01:00
|
|
|
state: directory
|
2021-05-27 16:18:04 +02:00
|
|
|
owner: "{{ weechat__user }}"
|
2020-03-11 21:08:00 +01:00
|
|
|
mode: "0750"
|
|
|
|
with_dict: "{{ weechat_plugin_languages }}"
|
|
|
|
|
2020-03-11 20:51:00 +01:00
|
|
|
- name: download weechat plugins
|
|
|
|
get_url:
|
|
|
|
url: 'https://weechat.org/files/scripts/{{ item }}'
|
2021-05-27 16:18:04 +02:00
|
|
|
dest: "{{ weechat__home_directory }}/.weechat/{{ weechat_plugin_languages[item.split('.',1)[-1]] }}/{{ item }}"
|
|
|
|
with_items: '{{ weechat__plugins }}'
|
2020-03-11 20:51:00 +01:00
|
|
|
|
|
|
|
- name: symlinking plugins to autoload
|
|
|
|
file:
|
2021-05-27 16:18:04 +02:00
|
|
|
src: "{{ weechat__home_directory }}/.weechat/{{ weechat_plugin_languages[item.split('.',1)[-1]] }}/{{ item }}"
|
|
|
|
dest: "{{ weechat__home_directory }}/.weechat/{{ weechat_plugin_languages[item.split('.',1)[-1]] }}/autoload/{{ item }}"
|
2020-03-11 20:51:00 +01:00
|
|
|
state: link
|
2021-05-27 16:18:04 +02:00
|
|
|
with_items: '{{ weechat__plugins }}'
|