From f23e8f5e65a6e32060c8fd6405d2fb1811c5d2c1 Mon Sep 17 00:00:00 2001 From: Franziska Kunsmann Date: Sun, 13 Feb 2022 08:47:44 +0100 Subject: [PATCH] new computer, who dis? --- .bin/backup-and-update-system | 34 +------------------------------- .config/i3/config | 16 ++++++--------- .config/i3pystatus/config.py | 27 +++++-------------------- .config/i3pystatus/ice-status.py | 2 +- .gnupg/gpg-agent.conf | 1 + 5 files changed, 14 insertions(+), 66 deletions(-) diff --git a/.bin/backup-and-update-system b/.bin/backup-and-update-system index 941ece1..b54b7ce 100755 --- a/.bin/backup-and-update-system +++ b/.bin/backup-and-update-system @@ -15,39 +15,7 @@ do done # Do a backup. -( - rsync -zaAP --numeric-ids --delete --relative \ - --rsync-path="/usr/bin/rsync --fake-super" \ - -e "ssh" --delete-excluded \ - --exclude "/home/kunsi/.cache/" \ - --exclude "/home/kunsi/.config/Ferdi/" \ - --exclude "/home/kunsi/.config/Rambox/" \ - --exclude "/home/kunsi/.local/lib/python*/site-packages/" \ - --exclude "/home/kunsi/.local/share/TelegramDesktop/tdata/user_data/cache/" \ - --exclude "/home/kunsi/.local/share/sddm/" \ - --exclude "/home/kunsi/.mozilla/firefox/*/storage/*" \ - --exclude "/home/kunsi/.npm/" \ - --exclude "/home/kunsi/.nvm/" \ - --exclude "/home/kunsi/.platformio/" \ - --exclude "/home/kunsi/.ssh/cm-*" \ - --exclude "/home/kunsi/.vdirsyncer" \ - --exclude "/home/kunsi/Downloads/" \ - --exclude "/home/kunsi/Schreibtisch/" \ - --exclude "/home/kunsi/VirtualBox VMs/" \ - --exclude "/home/kunsi/qemu/Windows_10.qcow2" \ - --exclude "/home/kunsi/tmp.*/" \ - "/home/kunsi" "$backup_ssh":backups/ - - # Exit code 24 means some files have vanished during rsync. - # I don't know why, but this is very common, apparently? - exitcode=$? - if [[ $exitcode != 0 ]] && [[ $exitcode != 24 ]] - then - exit 1 - fi -) -ssh $backup_ssh "sudo /usr/local/bin/rotate-single-backup-client kunsi-t470" - +sudo /usr/local/bin/generate-backup-with-retries printf '\a' # Do updates diff --git a/.config/i3/config b/.config/i3/config index b7335ea..c9a6a5e 100644 --- a/.config/i3/config +++ b/.config/i3/config @@ -5,8 +5,8 @@ font pango:DB Office Regular 9 floating_modifier $mod -bindsym $mod+Return exec xiate -bindsym $mod+Shift+Return exec xiate -class xiate-floating -e python +bindsym $mod+Return exec kitty +bindsym $mod+Shift+Return exec kitty --class terminal-floating -e python bindsym $mod+Shift+x kill @@ -98,7 +98,7 @@ force_display_urgency_hint 1000 ms focus_on_window_activation smart bar { - status_command python ~/.config/i3pystatus/config.py + status_command /opt/i3pystatus/venv/bin/python ~/.config/i3pystatus/config.py position top tray_output primary workspace_buttons yes @@ -108,7 +108,7 @@ for_window [window_role="pop-up"] floating enable for_window [class="Pavucontrol"] floating enable for_window [class="Gnome-calculator"] floating enable for_window [class="realvnc-vncviewer"] floating enable -for_window [class="xiate-floating"] floating enable +for_window [class="terminal-floating"] floating enable workspace $ws1 output DP2-2 workspace $ws2 output DP2-1 @@ -124,13 +124,9 @@ exec xset s noblank && xset s 90 10 && xset -dpms exec xsetroot -solid "#000000" exec xss-lock -n /home/kunsi/.bin/notify.sh -- /home/kunsi/.bin/screenlock.sh exec xinput disable 'SynPS/2 Synaptics TouchPad' -exec xinput disable 'ELAN Touchscreen' -#bindsym Control+$mod+l exec /home/kunsi/.bin/screenlock.sh bindsym XF86Tools exec /home/kunsi/.bin/screenlock.sh -bindsym XF86Display exec arandr - bindsym $mod+Prior exec pactl set-sink-volume @DEFAULT_SINK@ +2%; exec pactl set-sink-mute @DEFAULT_SINK@ 0 bindsym $mod+Next exec pactl set-sink-volume @DEFAULT_SINK@ -2%; exec pactl set-sink-mute @DEFAULT_SINK@ 0 bindsym XF86AudioRaiseVolume exec pactl set-sink-volume @DEFAULT_SINK@ +2%; exec pactl set-sink-mute @DEFAULT_SINK@ 0 @@ -138,8 +134,8 @@ bindsym XF86AudioLowerVolume exec pactl set-sink-volume @DEFAULT_SINK@ -2%; exec bindsym XF86AudioMute exec pactl set-sink-mute @DEFAULT_SINK@ toggle bindsym XF86AudioMicMute exec pactl set-source-mute alsa_input.pci-0000_00_1f.3.analog-stereo toggle -bindsym XF86MonBrightnessUp exec xbacklight +5 -bindsym XF86MonBrightnessDown exec xbacklight -5 +bindsym XF86MonBrightnessUp exec sudo light -A 5 +bindsym XF86MonBrightnessDown exec sudo light -U 5 bindsym $mod+Print exec maim ~/screenshot_$(date +%Y-%m-%d_%H%M%S).png bindsym $mod+Shift+Print exec maim -i $(xdotool getactivewindow) ~/screenshot_$(date +%Y-%m-%d_%H%M%S).png diff --git a/.config/i3pystatus/config.py b/.config/i3pystatus/config.py index ac02e9d..85a8e2b 100644 --- a/.config/i3pystatus/config.py +++ b/.config/i3pystatus/config.py @@ -8,7 +8,7 @@ status.register("pulseaudio", format="♪I {volume}%", format_muted="♪I -∞dB", step="2", - sink="alsa_output.pci-0000_00_1f.3.analog-stereo") + sink="alsa_output.pci-0000_07_00.6.HiFi__hw_Generic_1__sink") status.register("pulseaudio", format="♪D {volume}%", format_muted="♪D -∞dB", @@ -17,9 +17,9 @@ status.register("pulseaudio", status.register("backlight", format="{percentage}%", - backlight="intel_backlight", - on_leftclick="xbacklight =10", - on_rightclick="xbacklight =50", + backlight="amdgpu_bl0", + on_leftclick="sudo light -S 10", + on_rightclick="sudo light -S 50", interval=1) status.register("shell", @@ -42,16 +42,6 @@ status.register("battery", "CHR": "↑", "FULL": "", }) -status.register("battery", - battery_ident="BAT1", - format="B1: {status}{percentage:.2f}% {remaining:%E%h:%M}", - alert=True, - alert_percentage=5, - status={ - "DIS": "↓", - "CHR": "↑", - "FULL": "", - }) status.register("load", format="{avg1}") @@ -81,13 +71,6 @@ status.register("shell", on_leftclick='systemctl --user start redshift.service', on_rightclick='systemctl --user stop redshift.service', interval=1) -status.register("shell", - format="{output}", - hints = {"markup": "pango"}, - command="/home/kunsi/.config/i3pystatus/touchscreen.sh", - interval=1, - on_leftclick="xinput enable 'ELAN Touchscreen'", - on_rightclick="xinput disable 'ELAN Touchscreen'") status.register("shell", format="{output}", hints = {"markup": "pango"}, @@ -110,7 +93,7 @@ status.register("network", detect_active=True, freq_divisor=1000000000, divisor=1024, - on_leftclick="xiate -class xiate-floating -e sudo wifi-menu", + on_leftclick="kitty --class terminal-floating -e sudo wifi-menu", hints={"markup":"pango"}) #status.register("mpd", diff --git a/.config/i3pystatus/ice-status.py b/.config/i3pystatus/ice-status.py index c3a57e6..c4fab99 100755 --- a/.config/i3pystatus/ice-status.py +++ b/.config/i3pystatus/ice-status.py @@ -26,7 +26,7 @@ def format_time(seconds): try: - wifi_ssid = check_output("iw dev wlp4s0 link | awk '/SSID/ {print $2}'", shell=True).decode().strip().lower() + wifi_ssid = check_output("iw dev wlp3s0 link | awk '/SSID/ {print $2}'", shell=True).decode().strip().lower() if wifi_ssid not in ( 'wifi@db', diff --git a/.gnupg/gpg-agent.conf b/.gnupg/gpg-agent.conf index 5f48733..16dc82d 100644 --- a/.gnupg/gpg-agent.conf +++ b/.gnupg/gpg-agent.conf @@ -5,3 +5,4 @@ max-cache-ttl-ssh 30 no-allow-external-cache enable-ssh-support ignore-cache-for-signing +pinentry-program /usr/bin/pinentry-qt