diff options
Diffstat (limited to '.config/wal')
-rwxr-xr-x | .config/wal/postrun | 32 | ||||
-rw-r--r-- | .config/wal/templates/dunstrc | 79 | ||||
-rw-r--r-- | .config/wal/templates/zathurarc | 46 |
3 files changed, 157 insertions, 0 deletions
diff --git a/.config/wal/postrun b/.config/wal/postrun new file mode 100755 index 0000000..61d8a41 --- /dev/null +++ b/.config/wal/postrun @@ -0,0 +1,32 @@ +#!/bin/bash + +dunstconf="${XDG_CONFIG_HOME:-$HOME/.config}/dunst/dunstrc" +zathuraconf="${XDG_CONFIG_HOME:-$HOME/.config}/zathura/zathurarc" + +source "${XDG_CACHE_HOME:-$HOME/.cache}/wal/colors.sh" + +mkdir -p "${dunstconf%/*}" "${zathuraconf%/*}" + +mv -n "$dunstconf" "$dunstconf.bak" +mv -n "$zathuraconf" "$zathuraconf.bak" + +ln -sf "${XDG_CACHE_HOME:-$HOME/.cache}/wal/dunstrc" "$dunstconf" +ln -sf "${XDG_CACHE_HOME:-$HOME/.cache}/wal/zathurarc" "$zathuraconf" + +fix_sequences() { + e=$'\e' + sequences=$(cat) + foreground_color="$(echo -e "${sequences}\c" | grep --color=never -Eo "${e}]10[^${e}\\\\]*?${e}\\\\" | grep --color=never -Eo "#[0-9A-Fa-f]{6}")" + background_color="$(echo -e "${sequences}\c" | grep --color=never -Eo "${e}]11[^${e}\\\\]*?${e}\\\\" | grep --color=never -Eo "#[0-9A-Fa-f]{6}")" + cursor_color="$(echo -e "${sequences}\c" | grep --color=never -Eo "${e}]12[^${e}\\\\]*?${e}\\\\" | grep --color=never -Eo "#[0-9A-Fa-f]{6}")" + + for term in /dev/pts/{0..9}*; do + echo -e "\e]4;256;${cursor_color}\a\c" > "${term}" 2>/dev/null + echo -e "\e]4;258;${background_color}\a\c" > "${term}" 2>/dev/null + echo -e "\e]4;259;${foreground_color}\a\c" > "${term}" 2>/dev/null + done +} + +fix_sequences <"${XDG_CACHE_HOME:-$HOME/.cache}/wal/sequences" + +pkill dunst; setsid -f dunst diff --git a/.config/wal/templates/dunstrc b/.config/wal/templates/dunstrc new file mode 100644 index 0000000..ed6092f --- /dev/null +++ b/.config/wal/templates/dunstrc @@ -0,0 +1,79 @@ +[global] + monitor = 0 + follow = keyboard + offset = 10x30 + height = 200 + indicate_hidden = yes + shrink = no + transparency = 0 + notification_height = 0 + separator_height = 2 + padding = 8 + horizontal_padding = 8 + frame_width = 3 + frame_color = "{color8}" # Ensure color1 is defined in pywal + separator_color = auto + sort = yes + idle_threshold = 120 + font = JetBrains Mono Medium 10 + line_height = 0 + markup = full + format = "<b>%s</b>\n%b" + alignment = center + show_age_threshold = 60 + word_wrap = yes + ellipsize = middle + ignore_newline = no + stack_duplicates = true + hide_duplicate_count = false + show_indicators = yes + icon_position = left + max_icon_size = 32 + icon_path = /usr/share/icons/Papirus-Dark/16x16/status/:/usr/share/icons/Papirus-Dark/16x16/devices/ + sticky_history = yes + history_length = 20 + dmenu = /usr/bin/dmenu -p dunst: + browser = /usr/bin/firefox + always_run_script = true + title = Dunst + class = Dunst + startup_notification = false + verbosity = mesg + corner_radius = 5 + force_xinerama = false + mouse_left_click = do_action + mouse_middle_click = close_all + mouse_right_click = close_current + +[experimental] + per_monitor_dpi = false + +[shortcuts] + close = ctrl+space + close_all = ctrl+shift+space + history = ctrl+grave + context = ctrl+shift+period + +[urgency_low] + background = "{background}" # Set a valid color variable + foreground = "{foreground}" # Ensure color7 is defined in pywal + timeout = 5 + icon = /home/surgot/.config/dunst/normal.png + +[urgency_normal] + background = "{background}" # Use a valid background color + foreground = "{foreground}" # Ensure color4 is defined in pywal + timeout = 5 + icon = /home/surgot/.config/dunst/normal.png + +[urgency_critical] + background = "{background}" # Ensure color1 is defined in pywal + foreground = "{foreground}" + frame_color = "{color9}" # Ensure color11 is defined in pywal + timeout = 5 + icon = /home/surgot/.config/dunst/critical.png + +[play_sound] + summary = "*" + script = /home/surgot/.local/bin/alert + diff --git a/.config/wal/templates/zathurarc b/.config/wal/templates/zathurarc new file mode 100644 index 0000000..66527a8 --- /dev/null +++ b/.config/wal/templates/zathurarc @@ -0,0 +1,46 @@ +set sandbox none +set statusbar-h-padding 0 +set statusbar-v-padding 0 +set page-padding 1 +set selection-clipboard clipboard +map u scroll half-up +map d scroll half-down +map D toggle_page_mode +map r reload +map R rotate +map K zoom in +map J zoom out +map i recolor +map p print +map g goto top +map [fullscreen] u scroll half-up +map [fullscreen] d scroll half-down +map [fullscreen] D toggle_page_mode +map [fullscreen] r reload +map [fullscreen] R rotate +map [fullscreen] K zoom in +map [fullscreen] J zoom out +map [fullscreen] i recolor +map [fullscreen] p print +map [fullscreen] g goto top + +set default-bg "{background}" +set default-fg "{foreground}" +set statusbar-bg "{background}" +set statusbar-fg "{foreground}" +set inputbar-bg "{background}" +set inputbar-fg "{foreground}" +set notification-bg "{background}" +set notification-fg "{foreground}" +set notification-error-bg "{background}" +set notification-error-fg "{foreground}" +set notification-warning-bg "{background}" +set notification-warning-fg "{foreground}" +set highlight-color "{color3}" +set highlight-active-color "{color4}" +set completion-bg "{color3}" +set completion-fg "{color4}" +set completion-highlight-bg "{color3}" +set completion-highlight-fg "{color4}" +set recolor-lightcolor "{background}" +set recolor-darkcolor "{foreground}" |