From aa814b21f10265eee942c71bd21082708a0fd776 Mon Sep 17 00:00:00 2001 From: Sunderland93 Date: Fri, 5 May 2023 17:28:45 +0400 Subject: [PATCH] Add Swayr config --- .../config.d/40-autostart-applications.conf | 1 + etc/sway/variables | 7 ++- etc/xdg/swayr/config.toml | 46 +++++++++++++++++++ 3 files changed, 52 insertions(+), 2 deletions(-) create mode 100644 etc/xdg/swayr/config.toml diff --git a/etc/sway/config.d/40-autostart-applications.conf b/etc/sway/config.d/40-autostart-applications.conf index 45dd671..ff0ce73 100644 --- a/etc/sway/config.d/40-autostart-applications.conf +++ b/etc/sway/config.d/40-autostart-applications.conf @@ -21,4 +21,5 @@ exec_always { $watch_playerctl $calendar_daemon $import_gsettings + $swayr_daemon } diff --git a/etc/sway/variables b/etc/sway/variables index 4fe832c..8f24cf2 100644 --- a/etc/sway/variables +++ b/etc/sway/variables @@ -38,8 +38,8 @@ set $volume_up pulsemixer --change-volume +5 && $volume_bar set $volume_mute pulsemixer --toggle-mute && $volume_bar # clipboard history -set $clipboard cliphist list | fuzzel -dmenu -p "Select item to copy" --lines 10 --width 35 | cliphist decode | wl-copy -set $clipboard-del cliphist list | fuzzel -dmenu -p "Select item to delete" --lines 10 --width 35 | cliphist delete +set $clipboard cliphist list | fuzzel --dmenu -p "Select item to copy" --lines 10 --width 35 | cliphist decode | wl-copy +set $clipboard-del cliphist list | fuzzel --dmenu -p "Select item to delete" --lines 10 --width 35 | cliphist delete # Pulseaudo command set $pulseaudio $term_float pulsemixer @@ -95,6 +95,9 @@ set $dex_autostart '[ -x "$(command -v dex)" ] && gdbus wait --session org.kde.S # Start PCmanFM as a daemon set $pcmanfm_daemon '[ -x "$(command -v pcmanfm)" ] && pcmanfm -d' +# Swayr daemon +set $swayr_daemon '[ -x "$(command -v swayrd)" ] && env RUST_BACKTRACE=1 RUST_LOG=swayr=debug swayrd &> /tmp/swayrd.log' + # Power notifications daemon set $poweralertd '[ -x "$(command -v poweralertd)" ] && pkill poweralertd; poweralertd -s -i "line power" &' diff --git a/etc/xdg/swayr/config.toml b/etc/xdg/swayr/config.toml new file mode 100644 index 0000000..e01dcf6 --- /dev/null +++ b/etc/xdg/swayr/config.toml @@ -0,0 +1,46 @@ +[menu] +executable = 'fuzzel' +args = [ + '--dmenu',, + '-p','{prompt}', + '-font','Noto Sans 11', +] + +[format] +output_format = '{indent}Output {name} ({id})' +workspace_format = '{indent}Workspace {name} [{layout}] on output {output_name} ({id})' +container_format = '{indent}Container [{layout}] {marks} on workspace {workspace_name} ({id})' +window_format = "{indent}{app_name} — {urgency_start}“{title}”{urgency_end} {marks} on workspace {workspace_name} / {output_name} ({id})\u0000icon\u001f{app_icon}" +indent = ' ' +urgency_start = '' +urgency_end = '' +html_escape = true +icon_dirs = [ + '/usr/share/icons/hicolor/scalable/apps', + '/usr/share/icons/hicolor/64x64/apps', + '/usr/share/icons/hicolor/48x48/apps', + '/usr/share/icons/Adwaita/64x64/apps', + '/usr/share/icons/Adwaita/48x48/apps', + '/usr/share/pixmaps', +] + +[layout] +auto_tile = false +auto_tile_min_window_width_per_output_width = [ + [1024, 500], + [1280, 600], + [1400, 680], + [1440, 700], + [1600, 780], + [1920, 920], + [2560, 1000], + [3440, 1000], + [4096, 1200], +] + +[focus] +lockin_delay = 750 + +[misc] +auto_nop_delay = 3000 +seq_inhibit = false