diff --git a/bin/autostart.py b/bin/autostart.py new file mode 100755 index 0000000..5860e63 --- /dev/null +++ b/bin/autostart.py @@ -0,0 +1,16 @@ +#!/usr/bin/python +""" +Launch desktop files from ~/.config/autostart +""" + +import glob +import os.path +from gi.repository import Gio + +dirname = os.path.expanduser('~/.config/autostart') +for desktop in glob.glob(os.path.join(dirname, '*.desktop')): + try: + fp = Gio.DesktopAppInfo.new_from_filename(desktop) + except TypeError: + continue + fp.launch_uris([], None) diff --git a/bin/i3lock.sh b/bin/i3lock.sh index 679167e..448ec2b 100755 --- a/bin/i3lock.sh +++ b/bin/i3lock.sh @@ -1,6 +1,9 @@ #!/bin/sh +LOCKER="i3lock -c 000000" +/usr/bin/xss-lock -- "${LOCKER}" & exec /usr/bin/xautolock \ -time 5 \ - -locker "i3lock -c 000000" \ + -detectsleep \ + -locker "${LOCKER}" \ -notify 30 \ -notifier "notify-send -u critical -t 10000 -- 'LOCKING SCREEN IN 30 SECONDS'" diff --git a/dotfiles/config/i3/config b/dotfiles/config/i3/config index 1b612df..9ea31e6 100644 --- a/dotfiles/config/i3/config +++ b/dotfiles/config/i3/config @@ -130,7 +130,7 @@ bindsym $mod+l exec i3lock -c 000000 -d && xset dpms force off bindsym $alt+Control+l exec i3lock -c 000000 -d && xset dpms force off # things to start quickly -bindsym $mod+g exec /usr/bin/google-chrome-beta +bindsym $mod+g exec /usr/bin/google-chrome-beta --password-store=gnome # kill a window with middle click + mod bindsym --whole-window $mod+button2 kill @@ -141,6 +141,8 @@ bindsym --whole-window $mod+button3 floating toggle exec --no-startup-id /usr/bin/cinnamon-settings-daemon & exec --no-startup-id gnome-keyring-daemon --start --components=pkcs11,secrets exec --no-startup-id (sleep 2; nm-applet) & +exec --no-startup-id xset r rate 200 20 +exec --no-startup-id ~/bin/autostart.py # customize windows for_window [class="^google-chrome$"] border pixel diff --git a/dotfiles/config/i3status/config b/dotfiles/config/i3status/config new file mode 100644 index 0000000..07d68af --- /dev/null +++ b/dotfiles/config/i3status/config @@ -0,0 +1,52 @@ +# i3status configuration file. +# see "man i3status" for documentation. + +# It is important that this file is edited as UTF-8. +# The following line should contain a sharp s: +# ß +# If the above line is not correctly displayed, fix your editor first! + +general { + colors = true + interval = 5 +} + +order += "ipv6" +order += "disk /" +order += "disk /home" +order += "wireless _first_" +order += "ethernet _first_" +order += "battery all" +order += "load" +order += "tztime local" + +wireless _first_ { + format_up = "W: (%quality at %essid) %ip" + format_down = "W: down" +} + +ethernet _first_ { + # if you use %speed, i3status requires root privileges + format_up = "E: %ip (%speed)" + format_down = "E: down" +} + +battery all { + format = "%status %percentage %remaining" +} + +tztime local { + format = "%Y-%m-%d %H:%M:%S" +} + +load { + format = "%1min" +} + +disk "/" { + format = "%avail" +} + +disk "/home" { + format = "%avail" +} diff --git a/dotfiles/xinitrc b/dotfiles/xinitrc deleted file mode 100644 index 4453914..0000000 --- a/dotfiles/xinitrc +++ /dev/null @@ -1 +0,0 @@ -xset r rate 200 20