2017-12-18 22:18:38 +01:00
|
|
|
---
|
|
|
|
- name: Install weechat
|
2019-12-01 16:29:03 +01:00
|
|
|
package:
|
|
|
|
name:
|
|
|
|
- screen
|
|
|
|
- weechat
|
|
|
|
state: present
|
2017-12-18 22:18:38 +01:00
|
|
|
become: True
|
|
|
|
|
2019-12-01 16:29:03 +01:00
|
|
|
- name: Weechat in xprofile
|
|
|
|
copy:
|
|
|
|
src: weechat.sh
|
|
|
|
dest: ~/.xprofile.d/
|
2017-12-25 18:30:26 +01:00
|
|
|
when: ansible_user_id != "vagrant"
|
2017-12-20 21:09:02 +01:00
|
|
|
|
2017-12-25 18:42:39 +01:00
|
|
|
- name: Start weechat
|
|
|
|
shell: screen -DmS weechat /usr/bin/weechat &
|
|
|
|
changed_when: False
|
|
|
|
|
2017-12-22 13:25:54 +01:00
|
|
|
- name: Test if weechat fifo is enable
|
|
|
|
stat: path='~/.weechat/weechat_fifo'
|
|
|
|
register: stat_fifo
|
|
|
|
|
|
|
|
- debug:
|
|
|
|
msg: "Please active fifo with '/fifo enable' in weechat"
|
|
|
|
when: not stat_fifo.stat.exists
|
|
|
|
|
2017-12-20 21:09:02 +01:00
|
|
|
- name: Theme weechat
|
2019-12-01 16:29:03 +01:00
|
|
|
shell: echo {{item}} >~/.weechat/weechat_fifo
|
|
|
|
args:
|
|
|
|
creates: ~/.weechat/themed
|
|
|
|
loop:
|
2017-12-22 13:25:54 +01:00
|
|
|
- '*/bar hide nicklist'
|
|
|
|
- '*/bar show title'
|
|
|
|
- '*/bar hide status'
|
2017-12-28 16:41:29 +01:00
|
|
|
- '*/bar hide buflist'
|
2017-12-22 13:25:54 +01:00
|
|
|
- '*/script install colorize_nicks.py highmon.pl buffers.pl'
|
|
|
|
- '*/set weechat.look.separator_horizontal " "'
|
|
|
|
- '*/set weechat.look.prefix_suffix " "'
|
|
|
|
- '*/set buffers.color.hotlist_message_fg 7'
|
|
|
|
- '*/set buffers.color.current_bg 240'
|
|
|
|
- '*/set buffers.color.current_fg white'
|
|
|
|
- '*/set buffers.look.show_number off'
|
2017-12-20 21:47:07 +01:00
|
|
|
- '*/set weechat.bar.status.color_bg 0'
|
|
|
|
- '*/set weechat.bar.title.color_bg 0'
|
|
|
|
- '*/set weechat.color.chat_nick_colors 1,2,3,4,5,6'
|
|
|
|
- '*/set weechat.color.chat_highlight_bg red'
|
|
|
|
- '*/set weechat.color.chat_highlight black'
|
|
|
|
- '*/set weechat.bar.buffers.position top'
|
|
|
|
- '*/set weechat.bar.input.items " ,[input_search],[input_paste],input_text"'
|
|
|
|
- '*/set weechat.bar.input.color_delim 240'
|
|
|
|
- '*/set weechat.look.prefix_error "✘"'
|
|
|
|
- '*/set weechat.look.prefix_join ""'
|
|
|
|
- '*/set weechat.look.prefix_quit ""'
|
|
|
|
- '*/set weechat.look.read_marker none'
|
2017-12-20 21:53:04 +01:00
|
|
|
- '*/set env TERM screen-256color'
|
2017-12-20 22:00:50 +01:00
|
|
|
- '*/set weechat.look.buffer_time_format \${color:252}%H\${color:245}%M\${color:240}%S'
|
2017-12-22 13:25:54 +01:00
|
|
|
- '*/save'
|
|
|
|
- '*/reload'
|
2017-12-20 21:09:02 +01:00
|
|
|
|
|
|
|
- name: Create themed file
|
2019-12-01 16:29:03 +01:00
|
|
|
file:
|
|
|
|
path: ~/.weechat/themed
|
|
|
|
state: touch
|
|
|
|
changed_when: false
|