mirror of
https://github.com/eoli3n/dotfiles
synced 2024-11-22 23:12:32 +01:00
fixed polybar
This commit is contained in:
parent
6086e57571
commit
c32e98a9d3
@ -26,7 +26,7 @@ ok=${ok:-N}
|
||||
if [[ "$ok" == "y" ]]
|
||||
then
|
||||
echo "### DRYRUN ###################################################################"
|
||||
ansible-playbook -i "localhost," -c local install.yml --ask-become-pass -CD -t $1
|
||||
ansible-playbook -i "localhost," -c local install.yml --ask-become-pass -CD -t $1 || exit 1
|
||||
fi
|
||||
|
||||
echo "Do you want to install ? (Y/n)"
|
||||
|
@ -17,6 +17,10 @@
|
||||
- name: Add pkg check script
|
||||
copy: src=files/pkg.sh dest=~/.config/polybar/pkg.sh mode=0755
|
||||
|
||||
- name: Test if node specific template exists for launch.sh
|
||||
stat: path="{{ playbook_dir }}/roles/polybar/templates/{{ ansible_hostname }}/launch.j2"
|
||||
register: launch_file
|
||||
|
||||
- name: Template launch file
|
||||
template: src=templates/launch.j2 dest=~/.config/polybar/launch.sh mode=0755
|
||||
|
||||
|
@ -39,8 +39,7 @@ throttle-input-for = 30
|
||||
screenchange-reload = true
|
||||
|
||||
[bar/top]
|
||||
{% set template = ansible_hostname + '/launch.j2' %}
|
||||
{% if template|exists %}
|
||||
{% if launch_file.stat.exists %}
|
||||
monitor = ${env:MONITOR}
|
||||
monitor-strict = true
|
||||
{% else %}
|
||||
@ -103,8 +102,7 @@ tray-padding = 4
|
||||
;scroll-down = i3wm-wsprev
|
||||
|
||||
[bar/bottom]
|
||||
{% set template = ansible_hostname + '/launch.j2' %}
|
||||
{% if template|exists %}
|
||||
{% if launch_file.stat.exists %}
|
||||
monitor = ${env:MONITOR}
|
||||
monitor-strict = true
|
||||
{% else %}
|
||||
|
@ -7,10 +7,9 @@ killall -q polybar
|
||||
while pgrep -x polybar >/dev/null; do sleep 1; done
|
||||
|
||||
# Launch top and bottom
|
||||
{% set template = ansible_hostname + '/launch.j2' %}
|
||||
{% if template|exists %}
|
||||
{% include template %}
|
||||
{% else %}
|
||||
{% if launch_file.stat.exists %}
|
||||
{% include ansible_hostname + '/launch.j2' %}
|
||||
{% else %}
|
||||
polybar top &
|
||||
polybar bottom &
|
||||
{% endif %}
|
||||
|
Loading…
Reference in New Issue
Block a user