summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoger Gonzalez <roger@rogs.me>2024-08-07 09:42:07 -0300
committerRoger Gonzalez <roger@rogs.me>2024-08-07 09:42:07 -0300
commit5c4a2489186232248995909ba35105053efa3d60 (patch)
tree941cb24aa07d27b06ae4c74a477f9c9d76212ab3
parent2e9544cb385877770c1f3a71e209a8743a4a0793 (diff)
Added dnd mode and general i3 fixes
-rw-r--r--.config/i3/config24
-rwxr-xr-x.config/i3/i3status_script.delete.later.sh (renamed from .config/i3/i3status_script.sh)0
-rwxr-xr-x.config/i3/scripts/i3lock_script.sh (renamed from .config/i3/i3lock_script.sh)0
-rwxr-xr-x.config/i3/scripts/toggle_dnd.sh10
4 files changed, 20 insertions, 14 deletions
diff --git a/.config/i3/config b/.config/i3/config
index f8ff71bb..cb142cce 100644
--- a/.config/i3/config
+++ b/.config/i3/config
@@ -29,7 +29,7 @@ font pango:DejaVu Sans Mono 8
# xss-lock grabs a logind suspend inhibit lock and will use i3lock to lock the
# screen before suspend. Use loginctl lock-session to lock your screen.
-exec --no-startup-id xss-lock --transfer-sleep-lock ~/.config/i3/i3lock_script.sh
+exec --no-startup-id xss-lock --transfer-sleep-lock ~/.config/i3/scripts/i3lock_script.sh
# NetworkManager is the most popular way to manage wireless networks on Linux,
# and nm-applet is a desktop environment-independent system tray GUI for it.
@@ -192,7 +192,7 @@ bindsym $mod+Shift+c reload
# restart i3 inplace (preserves your layout/session, can be used to upgrade i3)
bindsym $mod+Shift+r restart
# lock the screen
-set $Locker exec "~/.config/i3/i3lock_script.sh"
+set $Locker exec "~/.config/i3/scripts/i3lock_script.sh"
set $mode_system System (l) lock, (e) logout, (s) suspend, (h) hibernate, (r) reboot, (Shift+s) shutdown
mode "$mode_system" {
@@ -229,12 +229,15 @@ bindsym --release Shift+F12 exec scrot -s -f ~/Pictures/%Y-%m-%d-%H%M%S.png
bindsym --release Ctrl+Shift+F12 exec scrot -s -f -o "/tmp/image.png" && xclip -selection clipboard -t image/png -i /tmp/image.png
bindsym --release Ctrl+Shift+F11 exec ksnip -r -p "/tmp/image.png"
+# Do not disturb
+bindsym $mod+m exec "~/.config/i3/scripts/toggle_dnd.sh"
+
# Shortcuts
bindsym $aux+g exec loffice ~/Documents/Gastos/Gastos\ USD.ods
bindsym $aux+u exec loffice ~/Documents/Gastos/Gastos\ UYU.ods
bindsym $aux+b exec loffice ~/Documents/Gastos/BTC.ods
-bindsym $aux+l exec lollypop
+bindsym $aux+l exec feishin
# Disable focus follows
focus_follows_mouse no
@@ -257,10 +260,9 @@ assign [class="Element"] $ws4
assign [class="Evolution"] $ws5
assign [class="thunderbird"] $ws5
assign [class="Mailspring"] $ws5
-assign [class="Liferea"] $ws9
-assign [class="NewsFlash"] $ws9
for_window [class = "Spotify"] move to workspace $ws6
assign [class="Lollypop"] $ws6
+assign [class="feishin"] $ws6
assign [class="Clementine"] $ws6
assign [class="Sublime-music"] $ws6
assign [class="Thunar"] $ws7
@@ -269,6 +271,8 @@ assign [class="KeePassXC"] $ws8
assign [class="Bitwarden"] $ws8
assign [class="Joplin"] $ws9
assign [class="kdeconnect.app"] $ws9
+assign [class="Liferea"] $ws9
+assign [class="NewsFlash"] $ws9
# Open specific applications in floating mode
for_window [title="File Transfer*"] floating enable
@@ -281,12 +285,7 @@ for_window [urgent=latest] focus
# Autostarts
exec --no-startup-id sleep 20; exec /usr/bin/thunderbird
-# exec --no-startup-id exec /usr/bin/mailspring
-exec --no-startup-id exec /usr/bin/nextcloud --background
-# exec --no-startup-id exec /usr/bin/evolution
-# exec_always --no-startup-id .config/conky/start.sh
exec --no-startup-id exec emacsclient -c -a emacs
-# exec --no-startup-id exec /usr/bin/librewolf
exec --no-startup-id sleep 5; exec /usr/bin/firefox
exec --no-startup-id sleep 5; exec $terminal
exec --no-startup-id sleep 10; exec nitrogen --restore
@@ -295,13 +294,10 @@ exec --no-startup-id /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1
exec --no-startup-id /usr/bin/unclutter
exec --no-startup-id xfce4-power-manager
exec --no-startup-id pamac-tray
-exec --no-startup-id exec /opt/Mullvad\ VPN/mullvad-gui --no-sandbox
exec_always --no-startup-id sleep 5; exec picom
exec --no-startup-id /usr/lib/xfce4/notifyd/xfce4-notifyd
exec_always --no-startup-id autotiling
exec --no-startup-id xinput set-prop 14 345 1
-exec --no-startup-id exec /usr/bin/bitwarden-desktop
-# exec --no-startup-id exec /usr/bin/keepassxc
exec --no-startup-id exec /usr/bin/play-with-mpv
exec --no-startup-id exec "~/.config/i3/connect-speakers.sh"
exec --no-startup-id sleep 5; exec /usr/bin/kdeconnect-app
@@ -309,7 +305,7 @@ exec dbus-update-activation-environment --systemd DBUS_SESSION_BUS_ADDRESS DISPL
# Random scripts
## Generate a random password and copy it to the clipboard
-bindsym $aux+p exec --no-startup-id "tr -dc 'A-Za-z0-9!#$%&'\''()*+,-./:;<=>?@[\]^_`{|}~' </dev/urandom | head -c 50 | xclip -selection clipboard && notify-send 'Copied a random password to the clipboard'"
+bindsym $aux+p exec --no-startup-id "tr -dc 'A-Za-z0-9!#$%&'\''()*+,-./:;<=>?@[\]^_`{|}~' </dev/urandom | head -c 50 | xclip -selection clipboard && notify-send 'Copied a random password to the clipboard' -i password"
# Window colors
# class border backgr. text indicator child_border
diff --git a/.config/i3/i3status_script.sh b/.config/i3/i3status_script.delete.later.sh
index b7788360..b7788360 100755
--- a/.config/i3/i3status_script.sh
+++ b/.config/i3/i3status_script.delete.later.sh
diff --git a/.config/i3/i3lock_script.sh b/.config/i3/scripts/i3lock_script.sh
index 4af57b56..4af57b56 100755
--- a/.config/i3/i3lock_script.sh
+++ b/.config/i3/scripts/i3lock_script.sh
diff --git a/.config/i3/scripts/toggle_dnd.sh b/.config/i3/scripts/toggle_dnd.sh
new file mode 100755
index 00000000..a11a4f83
--- /dev/null
+++ b/.config/i3/scripts/toggle_dnd.sh
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+state=$(xfconf-query -c xfce4-notifyd -p /do-not-disturb)
+if [ "$state" = "true" ]; then
+ xfconf-query -c xfce4-notifyd -p /do-not-disturb -s false
+ notify-send "Do not disturb: Disabled" -t 2000 -i notification
+else
+ xfconf-query -c xfce4-notifyd -p /do-not-disturb -s true
+ notify-send -u critical "Do not disturb: Enabled" -t 2000 -i notification
+fi