This commit is contained in:
ElKowar 2021-10-20 10:23:53 +02:00
parent e1e64ee274
commit 9cb9cd8f7c
4 changed files with 43 additions and 10 deletions

View file

@ -105,8 +105,8 @@
(let [rust-tools (require "rust-tools")] (let [rust-tools (require "rust-tools")]
(rust-tools.setup {:tools {:inlay_hints {:show_parameter_hints false} (rust-tools.setup {:tools {:inlay_hints {:show_parameter_hints false}
:autoSetHints false} :autoSetHints false}
:server {:on_attach on_attach :server {:on_attach on_attach}}))
:cmd ["/home/leon/coding/prs/rust-analyzer/target/release/rust-analyzer"]}})) ;:cmd ["/home/leon/coding/prs/rust-analyzer/target/release/rust-analyzer"]}}))
(let [sumneko_binary "/usr/bin/lua-language-server"] (let [sumneko_binary "/usr/bin/lua-language-server"]
(init-lsp (init-lsp

View file

@ -5,7 +5,7 @@
(telescope.setup (telescope.setup
{:defaults {:mappings {:i {:<esc> actions.close}} {:defaults {:mappings {:i {:<esc> actions.close}}
:file_ignore_patterns ["Cargo.lock" ".*.snap" "docs/theme/.*"]} :file_ignore_patterns ["Cargo.lock" ".*.snap" "docs/theme/.*" "node%_modules/.*" "target/.*"]}
:extensions {:frecency {:persistent_filter false}}}) :extensions {:frecency {:persistent_filter false}}})
(telescope.load_extension "frecency") (telescope.load_extension "frecency")

View file

@ -40,6 +40,22 @@ exec swayidle -w \
exec mako exec mako
exec libinput-gestures-setup start exec libinput-gestures-setup start
set $WOBSOCK $XDG_RUNTIME_DIR/wob.sock
exec mkfifo $WOBSOCK && tail -f $WOBSOCK | wob
exec_always import-gsettings
# brightness and volume popup
bindsym XF86AudioRaiseVolume exec pamixer -ui 2 && pamixer --get-volume > $WOBSOCK
bindsym XF86AudioLowerVolume exec pamixer -ud 2 && pamixer --get-volume > $WOBSOCK
bindsym XF86AudioMute exec pamixer --toggle-mute && ( pamixer --get-mute && echo 0 > $WOBSOCK ) || pamixer --get-volume > $WOBSOCK
bindsym XF86MonBrightnessDown exec brightnessctl set 5%- | sed -En 's/.*\(([0-9]+)%\).*/\1/p' | tee /tmp/brightness > $WOBSOCK
bindsym XF86MonBrightnessUp exec brightnessctl set +5% | sed -En 's/.*\(([0-9]+)%\).*/\1/p' | tee /tmp/brightness > $WOBSOCK
exec systemctl --user import-environment DISPLAY WAYLAND_DISPLAY SWAYSOCK
@ -48,10 +64,11 @@ gaps inner 10
default_border pixel 1 default_border pixel 1
client.focused "#ebdbb2" "#282828" "#8ec07c" "#8ec07c" "#ebdbb2"
client.unfocused "#1d2021" "#1d2021" "#ebdbb2" "#00000000"
client.focused_inactive "#282828" "#282828" "#8ec07c" "#00000000"
client.focused "#ebdbb2" "#ebdbb2" "#1d2021" hide_edge_borders smart
client.unfocused "#1d2021" "#1d2021" "#1d2021"
@ -184,10 +201,11 @@ input "type:keyboard" {
bindsym --locked XF86MonBrightnessUp exec brightnessctl -e set 50+ #bindsym --locked XF86MonBrightnessUp exec brightnessctl -e set 50+
bindsym --locked XF86MonBrightnessDown exec brightnessctl -e set 50- #bindsym --locked XF86MonBrightnessDown exec brightnessctl -e set 50-
bindsym --locked XF86AudioRaiseVolume exec pamixer -i 5
bindsym --locked XF86AudioLowerVolume exec pamixer -d 5 #bindsym --locked XF86AudioRaiseVolume exec pamixer -i 5
#bindsym --locked XF86AudioLowerVolume exec pamixer -d 5
bindsym $mod+Shift+S exec grimshot copy area bindsym $mod+Shift+S exec grimshot copy area
bindsym $mod+Shift+b exec google-chrome-stable bindsym $mod+Shift+b exec google-chrome-stable

View file

@ -0,0 +1,15 @@
#!/bin/sh
# usage: import-gsettings
config="${XDG_CONFIG_HOME:-$HOME/.config}/gtk-3.0/settings.ini"
if [ ! -f "$config" ]; then exit 1; fi
gnome_schema="org.gnome.desktop.interface"
gtk_theme="$(grep 'gtk-theme-name' "$config" | sed 's/.*\s*=\s*//')"
icon_theme="$(grep 'gtk-icon-theme-name' "$config" | sed 's/.*\s*=\s*//')"
cursor_theme="$(grep 'gtk-cursor-theme-name' "$config" | sed 's/.*\s*=\s*//')"
font_name="$(grep 'gtk-font-name' "$config" | sed 's/.*\s*=\s*//')"
gsettings set "$gnome_schema" gtk-theme "$gtk_theme"
gsettings set "$gnome_schema" icon-theme "$icon_theme"
gsettings set "$gnome_schema" cursor-theme "$cursor_theme"
gsettings set "$gnome_schema" font-name "$font_name"