ansible-desktop/roles/dwm/tasks/polybar.yml

64 lines
1.3 KiB
YAML
Raw Normal View History

2023-08-04 22:49:37 +00:00
---
2023-08-06 09:00:43 +00:00
- name: "polybar: install required packages"
2023-08-04 22:49:37 +00:00
become: yes
apt:
update_cache: yes
pkg:
- git
- make
- cmake
- libcairo2-dev
- libcurl4-openssl-dev
- libiw-dev
- libxcb-composite0-dev
- libxcb-randr0-dev
- xcb-proto
- libxcb-icccm4-dev
- libxcb-ewmh-dev
- libxcb-util-dev
- libxcb-image0-dev
- python3-xcbgen
2023-08-06 09:00:43 +00:00
- python3-sphinx
2023-08-04 22:49:37 +00:00
- libjsoncpp-dev
2023-08-07 08:39:18 +00:00
- libuv1-dev
2023-08-04 22:49:37 +00:00
2023-08-06 09:00:43 +00:00
- name: "polybar: create src dir"
2023-08-04 22:49:37 +00:00
file:
path: "{{ desktop_src_dir }}"
2023-08-04 22:49:37 +00:00
2023-08-06 09:00:43 +00:00
- name: "polybar: checkout"
2023-08-04 22:49:37 +00:00
git:
repo: "{{ polybar.repo }}"
dest: "{{ desktop_src_dir }}/polybar"
2023-08-04 22:49:37 +00:00
clone: yes
update: yes
2023-08-06 09:00:43 +00:00
- name: "polybar: create directory for build"
2023-08-04 22:49:37 +00:00
file:
state: directory
path: "{{ desktop_src_dir }}/polybar/build"
2023-08-04 22:49:37 +00:00
2023-08-06 09:00:43 +00:00
- name: "polybar: run cmake"
2023-08-04 22:49:37 +00:00
shell:
cmd: "cmake ../"
chdir: "{{ desktop_src_dir }}/polybar/build"
2023-08-04 22:49:37 +00:00
2023-08-06 09:00:43 +00:00
- name: "polybar: build"
2023-08-04 22:49:37 +00:00
make:
chdir: "{{ desktop_src_dir }}/polybar/build"
2023-08-06 09:00:43 +00:00
params:
NUM_THREADS: "{{ ansible_processor_vcpus }}"
2023-08-04 22:49:37 +00:00
2023-08-06 09:00:43 +00:00
- name: "polybar: install"
2023-08-04 22:49:37 +00:00
become: yes
make:
chdir: "{{ desktop_src_dir }}/polybar/build"
2023-08-04 22:49:37 +00:00
target: install
2023-08-06 09:00:43 +00:00
- name: "polybar: copy run script"
2023-08-04 22:49:37 +00:00
become: yes
copy:
src: usr/local/bin/launch-polybar
dest: /usr/local/bin/launch-polybar
mode: '0755'