update sway config
This commit is contained in:
parent
169953d51f
commit
8606da9f28
6 changed files with 94 additions and 17 deletions
|
|
@ -16,7 +16,21 @@ set $term alacritty
|
|||
# Your preferred application launcher
|
||||
# Note: pass the final command to swaymsg so that the resulting window can be opened
|
||||
# on the original workspace that the command was run on.
|
||||
set $menu bemenu-run
|
||||
set $menu bemenu-run -iw -l 20 -P '>' -p 'Open:' \
|
||||
--fn "JetBrainsMono 13" \
|
||||
--ab "#24273add" \
|
||||
--af "#f4dbd6" \
|
||||
--fb "#24273add" \
|
||||
--ff "#8bd5ca" \
|
||||
--hb "#24273add" \
|
||||
--hf "#a6da95" \
|
||||
--nb "#24273add" \
|
||||
--nf "#f4dbd6" \
|
||||
--nf "#f4dbd6" \
|
||||
--tb "#24273add" \
|
||||
--tf "#c6a0f6dd" \
|
||||
--scb "#24273add" \
|
||||
--scf "#c6a0f6"
|
||||
|
||||
### Output configuration
|
||||
#
|
||||
|
|
@ -33,11 +47,10 @@ output * bg ~/Pictures/wallpaper.png fill
|
|||
#
|
||||
# Example configuration:
|
||||
#
|
||||
exec swayidle -w \
|
||||
timeout 300 'swaylock -f -c 000000' \
|
||||
timeout 600 'swaymsg "output * dpms off"' resume 'swaymsg "output * dpms on"' \
|
||||
before-sleep 'swaylock -f -c 000000'
|
||||
#
|
||||
exec swayidle -w \
|
||||
timeout 300 'systemctl suspend' \
|
||||
before-sleep '~/.config/sway/lock.sh'
|
||||
|
||||
# This will lock your screen after 300 seconds of inactivity, then turn off
|
||||
# your displays after another 300 seconds, and turn your screens back on when
|
||||
# resumed. It will also lock your screen before your computer goes to sleep.
|
||||
|
|
@ -112,7 +125,7 @@ input "type:keyboard" {
|
|||
# Workspaces:
|
||||
#
|
||||
# Switch to workspace
|
||||
bindsym $mod+slash workspace back_and_forth
|
||||
bindsym $mod+bar workspace back_and_forth
|
||||
bindsym $mod+1 workspace number 1
|
||||
bindsym $mod+2 workspace number 2
|
||||
bindsym $mod+3 workspace number 3
|
||||
|
|
@ -174,12 +187,15 @@ input "type:keyboard" {
|
|||
#
|
||||
# screenshot current window
|
||||
bindsym print exec grim -g "$(swaymsg -t get_tree | jq -j '.. | select(.type?) | select(.focused).rect | "\(.x),\(.y) \(.width)x\(.height)"')" - | wl-copy
|
||||
# screenshot area
|
||||
bindsym print+shift exec grim -g "$(slurp)" - | wl-copy
|
||||
# screenshot area and edit it
|
||||
bindsym print+ctrl exec grim -g "$(slurp)" - | swappy -f -
|
||||
|
||||
bindsym XF86AudioRaiseVolume exec pactl set-sink-volume @DEFAULT_SINK@ +5%
|
||||
bindsym XF86AudioLowerVolume exec pactl set-sink-volume @DEFAULT_SINK@ -5%
|
||||
bindsym XF86AudioMute exec pactl set-sink-mute @DEFAULT_SINK@ toggle
|
||||
bindsym XF86AudioMicMute exec pactl set-source-mute @DEFAULT_SOURCE@ toggle
|
||||
bindsym XF86AudioRaiseVolume exec wpctl set-volume -l 1.0 @DEFAULT_AUDIO_SINK@ 5%+
|
||||
bindsym XF86AudioLowerVolume exec wpctl set-volume -l 1.0 @DEFAULT_AUDIO_SINK@ 5%-
|
||||
bindsym XF86AudioMute exec wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle
|
||||
bindsym XF86AudioMicMute exec wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle
|
||||
bindsym XF86AudioPlay exec playerctl play-pause
|
||||
bindsym XF86AudioNext exec playerctl next
|
||||
bindsym XF86AudioPrev exec playerctl previous
|
||||
|
|
@ -230,13 +246,27 @@ bar {
|
|||
|
||||
# Start Stuff
|
||||
|
||||
# create a master stack layout
|
||||
exec_always autotiling -l 2
|
||||
exec dbus-update-activation-environment --systemd DISPLAY WAYLAND_DISPLAY SWAYSOCK
|
||||
exec monitor-sensor | bash $DOTS/config/sway/autorotate &> /tmp/autorotate.log
|
||||
exec mako
|
||||
|
||||
# Auto rotate screen
|
||||
# 1 option uses accelerometer (requires iio-sensors-proxy)
|
||||
# 2 option uses tablet events
|
||||
|
||||
# exec monitor-sensor | bash $DOTS/config/sway/autorotate &> /tmp/autorotate.log
|
||||
bindswitch tablet:toggle output "eDP-1" transform 180 clockwise
|
||||
# bindswitch lid:toggle exec echo "Lid moved" &>/tmp/lid.log
|
||||
|
||||
bindgesture swipe:left workspace prev
|
||||
bindgesture swipe:right workspace next
|
||||
bindgesture swipe:up scratchpad show
|
||||
|
||||
gaps inner 10
|
||||
gaps outer 2
|
||||
|
||||
smart_borders on
|
||||
default_border pixel 2
|
||||
default_floating_border pixel 2
|
||||
|
||||
xwayland enable
|
||||
|
||||
|
|
|
|||
17
config/sway/lock.sh
Executable file
17
config/sway/lock.sh
Executable file
|
|
@ -0,0 +1,17 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
swaylock \
|
||||
--screenshots \
|
||||
--clock \
|
||||
--indicator \
|
||||
--indicator-radius 100 \
|
||||
--indicator-thickness 7 \
|
||||
--effect-blur 7x5 \
|
||||
--effect-vignette 0.5:0.5 \
|
||||
--ring-color 3b4252 \
|
||||
--key-hl-color 880033 \
|
||||
--line-color 00000000 \
|
||||
--inside-color 00000088 \
|
||||
--separator-color 00000000 \
|
||||
--grace 2 \
|
||||
--fade-in 0.3
|
||||
Loading…
Add table
Add a link
Reference in a new issue