mirror of
https://github.com/roles-ansible/ansible_role_weechat.git
synced 2024-08-16 13:09:48 +02:00
improve and rewrite weechat plugin task
This commit is contained in:
parent
1562f8bc02
commit
bb070de812
6 changed files with 25 additions and 29 deletions
|
@ -4,8 +4,8 @@ weechat:
|
||||||
install: true
|
install: true
|
||||||
# autostart weechat via systemd in a tmux session?
|
# autostart weechat via systemd in a tmux session?
|
||||||
autostart: false
|
autostart: false
|
||||||
# should we configure weechat
|
# should we install official weechat plugins
|
||||||
configure: false
|
install_plugins: false
|
||||||
# user to install and use weechat
|
# user to install and use weechat
|
||||||
user: "{{ ansible_user_id }}"
|
user: "{{ ansible_user_id }}"
|
||||||
# where is our home direcotory for weechat
|
# where is our home direcotory for weechat
|
||||||
|
|
|
@ -1,19 +0,0 @@
|
||||||
---
|
|
||||||
- name: create weechat directory
|
|
||||||
become: true
|
|
||||||
become_user: "{{ weechat.user }}"
|
|
||||||
file:
|
|
||||||
path: "{{ weechat.home_directory }}"
|
|
||||||
state: directory
|
|
||||||
owner: "{{ weechat.user }}"
|
|
||||||
mode: "0750"
|
|
||||||
|
|
||||||
- name: create weechat plugins directory
|
|
||||||
become: true
|
|
||||||
become_user: "{{ weechat.user }}"
|
|
||||||
file:
|
|
||||||
path: "{{ weechat.home_directory }}/{{ item.value }}/autoload"
|
|
||||||
state: directory
|
|
||||||
owner: "{{ weechat.user }}"
|
|
||||||
mode: "0750"
|
|
||||||
with_dict: "{{ weechat_plugin_languages }}"
|
|
|
@ -1,4 +1,23 @@
|
||||||
---
|
---
|
||||||
|
- name: create weechat directory
|
||||||
|
become: true
|
||||||
|
become_user: "{{ weechat.user }}"
|
||||||
|
file:
|
||||||
|
path: "{{ weechat.home_directory }}"
|
||||||
|
state: directory
|
||||||
|
owner: "{{ weechat.user }}"
|
||||||
|
mode: "0750"
|
||||||
|
|
||||||
|
- name: create weechat plugins directory
|
||||||
|
become: true
|
||||||
|
become_user: "{{ weechat.user }}"
|
||||||
|
file:
|
||||||
|
path: "{{ weechat.home_directory }}/{{ item.value }}/autoload"
|
||||||
|
state: directory
|
||||||
|
owner: "{{ weechat.user }}"
|
||||||
|
mode: "0750"
|
||||||
|
with_dict: "{{ weechat_plugin_languages }}"
|
||||||
|
|
||||||
- name: download weechat plugins
|
- name: download weechat plugins
|
||||||
get_url:
|
get_url:
|
||||||
url: 'https://weechat.org/files/scripts/{{ item }}'
|
url: 'https://weechat.org/files/scripts/{{ item }}'
|
||||||
|
|
|
@ -1,4 +0,0 @@
|
||||||
---
|
|
||||||
- include_tasks: configure_directorys.yml
|
|
||||||
|
|
||||||
- include_tasks: configure_plugins.yml
|
|
|
@ -9,8 +9,8 @@
|
||||||
- include_tasks: "install-{{ ansible_os_family|lower }}.yml"
|
- include_tasks: "install-{{ ansible_os_family|lower }}.yml"
|
||||||
when: weechat.install | bool
|
when: weechat.install | bool
|
||||||
|
|
||||||
- include_tasks: configure_weechat.yml
|
- include_tasks: configure_plugins.yml
|
||||||
when: weechat.configure | bool
|
when: weechat.install_plugins | bool
|
||||||
|
|
||||||
- include_tasks: setup_autostart.yml
|
- include_tasks: setup_autostart.yml
|
||||||
when: weechat.autostart | bool
|
when: weechat.autostart | bool
|
||||||
|
|
|
@ -9,14 +9,14 @@ weechat_plugin_languages:
|
||||||
lua: lua
|
lua: lua
|
||||||
|
|
||||||
# version management
|
# version management
|
||||||
playbook_version_number: 2054 # should be over ninethousand
|
playbook_version_number: 2055 # should be over ninethousand
|
||||||
playbook_version_path: 'role-weechat_roles-ansible_github.com.version'
|
playbook_version_path: 'role-weechat_roles-ansible_github.com.version'
|
||||||
|
|
||||||
# default values
|
# default values
|
||||||
_weechat:
|
_weechat:
|
||||||
install: true
|
install: true
|
||||||
autostart: false
|
autostart: false
|
||||||
configure: false
|
install_plugins: false
|
||||||
user: "{{ ansible_user_id }}"
|
user: "{{ ansible_user_id }}"
|
||||||
home_directory: "{{ ansible_env.HOME | default('/home/{{ weechat.user }}') }}/.weechat"
|
home_directory: "{{ ansible_env.HOME | default('/home/{{ weechat.user }}') }}/.weechat"
|
||||||
plugins: []
|
plugins: []
|
||||||
|
|
Loading…
Reference in a new issue