aboutsummaryrefslogtreecommitdiff
path: root/.config
diff options
context:
space:
mode:
authoreug-vs <eug-vs@keemail.me>2021-02-28 22:01:26 +0300
committereug-vs <eug-vs@keemail.me>2021-02-28 22:01:26 +0300
commitc51b3ad04df0f5b9048c326ab39b060a2f5f4805 (patch)
tree4eff5ce2cca3af60f906950273814b886ecd76c9 /.config
parentf48df5d6d39e8e98e9ce43fb1359ebc335b09235 (diff)
downloaddotfiles-c51b3ad04df0f5b9048c326ab39b060a2f5f4805.tar.gz
feat(i3): upgrade i3-blocks
Diffstat (limited to '.config')
-rw-r--r--.config/i3/config7
-rw-r--r--.config/i3blocks-modules/conf8
-rw-r--r--.config/i3blocks/i3blocks.conf32
3 files changed, 45 insertions, 2 deletions
diff --git a/.config/i3/config b/.config/i3/config
index de6d630..e85826a 100644
--- a/.config/i3/config
+++ b/.config/i3/config
@@ -14,7 +14,7 @@ exec --no-startup-id xss-lock --transfer-sleep-lock -- i3lock --nofork
exec --no-startup-id nm-applet
# Use pactl to adjust volume in PulseAudio and display it in Volnoti
-set $show_volume volnoti-show $(amixer get Master | grep -Po '[0-9]+(?=%)' | head -1)
+set $show_volume volnoti-show $(pactl list sinks | grep '^[[:space:]]Volume:' | head -n $(( $SINK + 1 )) | tail -n 1 | sed -e 's,.* \([0-9][0-9]*\)%.*,\1,')
bindsym XF86AudioRaiseVolume exec --no-startup-id "pactl set-sink-volume @DEFAULT_SINK@ +5% && $show_volume"
bindsym XF86AudioLowerVolume exec --no-startup-id "pactl set-sink-volume @DEFAULT_SINK@ -5% && $show_volume"
bindsym XF86AudioMute exec --no-startup-id "pactl set-sink-mute @DEFAULT_SINK@ toggle && if amixer get Master | grep -Fq '[off]'; then volnoti-show -m; else $show_volume; fi"
@@ -203,9 +203,12 @@ gaps inner 12
# i3blocks
bar {
- status_command i3blocks -c ~/.config/i3blocks.conf
+ status_command i3blocks -c ~/.config/i3blocks/i3blocks.conf
+ font pango:DejaVuSansMono Nerd Font 9
+ height 26
position top
colors {
+ background #111111
focused_workspace $yellow $yellow #000000
active_workspace #333333 #333333 $purple
inactive_workspace #CECECE #333333 #f1f1f1
diff --git a/.config/i3blocks-modules/conf b/.config/i3blocks-modules/conf
new file mode 100644
index 0000000..827f626
--- /dev/null
+++ b/.config/i3blocks-modules/conf
@@ -0,0 +1,8 @@
+# i3blocks-modules color configuration
+
+# Set your default colors
+color_def="#CCCCCC"
+color_good="#CCCCCC"
+color_warn="#ccdc90"
+color_crit="#e89393"
+color_info="#FCE94F"
diff --git a/.config/i3blocks/i3blocks.conf b/.config/i3blocks/i3blocks.conf
new file mode 100644
index 0000000..d87c4b2
--- /dev/null
+++ b/.config/i3blocks/i3blocks.conf
@@ -0,0 +1,32 @@
+markup=pango
+separator=false
+separator_block_width=25
+
+[lang]
+command=bash -c 'xkb-switch; xkb-switch -W'
+interval=persist
+
+[volume]
+command=~/.local/share/i3blocks-modules/volume
+interval=1
+
+[backlight]
+command=~/.local/share/i3blocks-modules/backlight
+interval=1
+
+[wifi]
+command=~/.local/share/i3blocks-modules/wifi -f ' {ssid}'
+interval=5
+
+[battery]
+command=~/.local/share/i3blocks-modules/battery -f ' {percent}%'
+interval=1
+
+[date]
+command=~/.local/share/i3blocks-modules/date -f " {time}" -t "%a, %d.%m.%Y"
+interval=60
+
+[time]
+command=~/.local/share/i3blocks-modules/date -f " {time}" -t "%H:%M:%S"
+interval=1
+