configs/desktop/configs/sway/config
Lucas Barbieri 4f87eb7f23 add the rest of it
lots of changes :)
2023-10-09 18:27:04 -03:00

298 lines
11 KiB
Plaintext

### Variables
set $mod Mod4
set $left h
set $down j
set $up k
set $right l
set $term kitty
set $menu ~/.config/rofi/launchers/type-6/launcher.sh
# exec linux-wallpaperengine 2937346640 --screen-root HDMI-A-1 --silent --fps 30
# output DP-1 bg ~/Pictures/wallpapers/FouGLjX.png fill
output DP-1 bg ~/Pictures/wallpapers/HHN8.png fill
# exec linux-wallpaperengine 2920910376 --screen-root DP-1 --silent --fps 30
output HDMI-A-1 bg ~/Pictures/wallpapers/FouGLjX.png fill
#
output DP-1 resolution 1920x1080 position 0,0 adaptive_sync on
# output HDMI-A-1 resolution 1920x1080 position 1920,-145 # negative indeces dont work xwayland
# gtk theme
set $gnome-schema org.gnome.desktop.interface
exec_always {
gsettings set $gnome-schema gtk-theme 'Gruvbox-Dark-BL-LB'
gsettings set $gnome-schema icon-theme 'Nordzy-green-dark'
gsettings set $gnome-schema cursor-theme 'oreo_white_cursors'
gsettings set $gnome-schema font-name 'Cartograph CF 13'
}
seat seat0 xcursor_theme oreo_white_cursors 16
exec swayidle -w \
timeout 300 'swaylock -f -c 000000 -i /home/jab/Pictures/wallpapers/ce9n8lbxes4b1.jpg' \
timeout 600 'swaymsg "output * dpms off"' resume 'swaymsg "output * dpms on"' \
before-sleep 'swaylock -f -c 000000 -i /home/jab/Pictures/wallpapers/ce9n8lbxes4b1.jpg'
# exec xrandr --output DP-1 --primary
exec waybar
exec otd
exec mpd
exec lxqt-policykit
exec nmcli con up Wired\ Connection\ 1
exec_always autotiling
exec redshift -t 4500:3500 -l -23.5475:-46.63611 -b 1.0:0.7 &
exec dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=sway
exec touch ~/tmp/swaylol
exec rm -rf ~/tmp/*
exec umount ~/xabu
exec sshfs server:/home/xabu ~/xabu -o reconnect
### Input configuration
#
# Example configuration:
#
input "2362:9523:Gaming_Mouse" {
accel_profile flat
dwt enabled
middle_emulation enabled
pointer_accel 0.5
}
input "3141:20484:SONiX_USB_DEVICE" {
xkb_layout br
xkb_variant abnt2
}
input "1356:2508:Wireless_Controller_Touchpad" {
map_to_output DISABLED
}
#
# You can get the names of your inputs by running: swaymsg -t get_inputs
# Read `man 5 sway-input` for more information about this section.
### Key bindings
# Basics:
# Start a terminal
bindsym $mod+Return exec $term
# Kill focused window
bindsym $mod+Shift+c kill
# Start your launcher
bindsym $mod+Shift+Return exec $menu
# Drag floating windows by holding down $mod and left mouse button.
# Resize them with right mouse button + $mod.
# Despite the name, also works for non-floating windows.
# Change normal to inverse to use left mouse button for resizing and right
# mouse button for dragging.
floating_modifier $mod normal
# Reload the configuration file
bindsym $mod+Shift+r reload
# Exit sway (logs you out of your Wayland session)
bindsym $mod+Shift+q exec swaynag -t warning -m 'You pressed the exit shortcut. Do you really want to exit sway? This will end your Wayland session.' -B 'Yes, exit sway' 'swaymsg exit'
#
# Moving around:
#
# Move your focus around
bindsym $mod+$up focus left
# bindsym $mod+$down focus down
# bindsym $mod+$up focus up
bindsym $mod+$down focus right
# Or use $mod+[up|down|left|right]
bindsym $mod+Left focus left
bindsym $mod+Down focus down
bindsym $mod+Up focus up
bindsym $mod+Right focus right
# Move the focused window with the same, but add Shift
bindsym $mod+Shift+$up move left
# bindsym $mod+Shift+$down move down
# bindsym $mod+Shift+$up move up
bindsym $mod+Shift+$down move right
# Ditto, with arrow keys
bindsym $mod+Shift+Left move left
bindsym $mod+Shift+Down move down
bindsym $mod+Shift+Up move up
bindsym $mod+Shift+Right move right
#
# Workspaces:
#
bindsym $mod+1 exec ~/.config/sway/xmonad workspace 1
bindsym $mod+2 exec ~/.config/sway/xmonad workspace 2
bindsym $mod+3 exec ~/.config/sway/xmonad workspace 3
bindsym $mod+4 exec ~/.config/sway/xmonad workspace 4
bindsym $mod+5 exec ~/.config/sway/xmonad workspace 5
bindsym $mod+6 exec ~/.config/sway/xmonad workspace 6
bindsym $mod+7 exec ~/.config/sway/xmonad workspace 7
bindsym $mod+8 exec ~/.config/sway/xmonad workspace 8
bindsym $mod+Shift+1 move container to workspace number 1
bindsym $mod+Shift+2 move container to workspace number 2
bindsym $mod+Shift+3 move container to workspace number 3
bindsym $mod+Shift+4 move container to workspace number 4
bindsym $mod+Shift+5 move container to workspace number 5
bindsym $mod+Shift+6 move container to workspace number 6
bindsym $mod+Shift+7 move container to workspace number 7
bindsym $mod+Shift+8 move container to workspace number 8
#
# Layout stuff:
#
# You can "split" the current object of your focus with
# $mod+b or $mod+v, for horizontal and vertical splits
# respectively.
bindsym $mod+h splith
bindsym $mod+v splitv
# Switch the current container between different layout styles
bindsym $mod+s layout stacking
bindsym $mod+w layout tabbed
bindsym $mod+Shift+e layout toggle split
# Make the current focus fullscreen
bindsym $mod+f fullscreen
# Toggle the current focus between tiling and floating mode
bindsym $mod+t floating toggle
# Swap focus between the tiling area and the floating area
bindsym $mod+space focus mode_toggle
# Move focus to the parent container
bindsym $mod+a focus parent
bindsym $mod+comma focus output DP-1
bindsym $mod+period focus output HDMI-A-1
bindsym $mod+Shift+comma move container to output left
bindsym $mod+Shift+period move container to output right
#
# Scratchpad:
#
# Sway has a "scratchpad", which is a bag of holding for windows.
# You can send windows there and get them back later.
# Move the currently focused window to the scratchpad
bindsym $mod+Control+Return move scratchpad
# Show the next scratchpad window or hide the focused scratchpad window.
# If there are multiple scratchpad windows, this command cycles through them.
bindsym $mod+Control+s scratchpad show
#
# Resizing containers:
#
mode "resize" {
# left will shrink the containers width
# right will grow the containers width
# up will shrink the containers height
# down will grow the containers height
bindsym $left resize shrink width 40px
bindsym $down resize grow height 40px
bindsym $up resize shrink height 40px
bindsym $right resize grow width 40px
# Ditto, with arrow keys
bindsym Left resize shrink width 40px
bindsym Down resize grow height 40px
bindsym Up resize shrink height 40px
bindsym Right resize grow width 40px
# Return to default mode
bindsym Return mode "default"
bindsym Escape mode "default"
}
bindsym $mod+r mode "resize"
bindsym $mod+b exec ~/.config/sway/firefox-to-workspace.sh main 2
bindsym $mod+Shift+b exec ~/.config/sway/firefox-to-workspace.sh dev 5
bindsym $mod+Control+b exec ~/.config/sway/firefox-to-workspace.sh school 7
bindsym $mod+F1 exec mpc prev
bindsym $mod+F2 exec mpc next
bindsym $mod+Escape exec mpc toggle
bindsym $mod+Control+l exec sudo lutris-chroot
bindsym $mod+Control+x exec GTK_THEME=Orchis-Dark xournalpp
bindsym $mod+Alt+x exec LD_PRELOAD="$LD_PRELOAD:/usr/\$LIB/libgamemodeauto.so.0" XL_SECRET_PROVIDER=FILE xivlauncher
bindsym $mod+Control+o exec VK_ICD_FILENAMES=/usr/share/vulkan/icd.d/amd_pro_icd64.json obs
bindsym $mod+Shift+i exec ~/.local/share/idea-IC/bin/idea.sh
bindsym $mod+Shift+d exec flatpak run de.shorsh.discord-screenaudio
default_border pixel 2
client.focused #cb4b16 #cb4b16 #cb4b16
focus_on_window_activation none
popup_during_fullscreen smart
no_focus [window_role="pop-up"]
corner_radius 8
shadows on
shadows_on_csd on
shadow_blur_radius 80
blur enable
blur_radius 3
blur_passes 3
gaps inner 8
for_window [class="discord"] move to workspace 3
for_window [class="Anki" title="Add"] floating enable
for_window [class="VencordDesktop"] move to workspace 3
for_window [shell=".*"] inhibit_idle fullscreen
for_window [class="obsidian"] move to workspace 6
for_window [class="xournalpp"] move to workspace 7
for_window [app_id=".*office.*"] move to workspace 5
for_window [app_id="WebCord"] move to workspace 3
for_window [app_id="de.shorsh.discord-screenaudio"] move to workspace 3
for_window [app_id="SGDBoop"] floating enable
for_window [class="Steam"] move to workspace 8
for_window [class="steam"] move to workspace 8
for_window [class=".*jetbrains.*"] move to workspace 4
for_window [app_id="lutris"] move to workspace 5
for_window [class="heroic"] move to workspace 5
for_window [class="explorer.exe"] move to workspace 4
for_window [class="osu!"] move to workspace 4
for_window [title="Wine System Tray"] kill
for_window [app_id="org.prismlauncher.PrismLauncher"] move to workspace 5
for_window [class="ffxiv_dx11.exe"] move to workspace 4, floating enable
for_window [class="battle.net.exe"] move to workspace 4, floating enable
for_window [class="diablo iv.exe"] move to workspace 4, floating enable
for_window [class=".*Minecraft.*"] move to workspace 4, floating enable
for_window [class="XIVLauncher.Core"] move to workspace 4, floating enable
for_window [class=".*league.*"] move to workspace 4, floating enable
assign [class="league of legends.exe"] 4
for_window [class=".*riot.*"] move to workspace 4, floating enable
for_window [class=".*csgo.*"] move to workspace 4, floating enable
assign [class="gamescope"] 4
for_window [class="gamescope"] floating enable
for_window [class=".*steam_.*"] move to workspace 4, floating enable
# firefox tweaks
for_window [title = "Firefox - Sharing Indicator"] kill
for_window [title = "About Mozilla Firefox"] floating enable
for_window [window_role = "About"] floating enable
for_window [app_id="firefox" title="Library"] floating enable, border pixel 1, sticky enable
for_window [title = "Firefox — Sharing Indicator"] kill
# steam tweaks
for_window [class="^Steam$" title="^Friends$"] floating enable
for_window [class="^Steam$" title="Steam - News"] floating enable
for_window [class="^Steam$" title=".* - Chat"] floating enable
for_window [class="^Steam$" title="^Settings$"] floating enable
for_window [class="^Steam$" title=".* - event started"] floating enable
for_window [class="^Steam$" title=".* CD key"] floating enable
for_window [class="^Steam$" title="^Steam - Self Updater$"] floating enable
for_window [class="^Steam$" title="^Screenshot Uploader$"] floating enable
for_window [class="^Steam$" title="^Steam Guard - Computer Authorization Required$"] floating enable
for_window [title="^Steam Keyboard$"] floating enable
# jetbrains
bindsym $mod+Shift+s exec steam --noverifyfiles
bindsym $mod+e exec thunar
bindsym Print exec ~/.local/bin/print-fullscreen
bindsym Shift+Print exec ~/.local/bin/print-select
bindsym Control+Shift+Print exec ~/.local/bin/print-tmp
bindsym Control+Print exec ~/.local/bin/print-window.sh
# audio
bindsym XF86AudioRaiseVolume exec wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+
bindsym XF86AudioLowerVolume exec wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-
include /etc/sway/config.d/*