This commit is contained in:
fz0x1 2024-11-18 18:11:06 +01:00
parent 7aee7348cf
commit 01150ca2fa
10 changed files with 84 additions and 34 deletions

Binary file not shown.

5
global/scripts/bin/lock.sh Executable file
View file

@ -0,0 +1,5 @@
#!/usr/bin/env sh
pkill -u "$USER" -USR1 dunst
~/.config/i3/i3lock
pkill -u "$USER" -USR2 dunst

View file

@ -0,0 +1,31 @@
#!/usr/bin/env bash
if (($# != 1)); then
echo "Error! No mode. Use: screenshot.sh full|region"
exit 2
fi
mode=$1
screenshot="$HOME/Screenshots/screenshot-$(date +'%Y_%m_%d-%H_%M_%S').png"
if [[ "$(uname)" == "Darwin" ]]; then
echo "Not implemented yet"
exit 0
elif [[ "$(uname)" == "Linux" ]]; then
case $mode in
full)
maim $screenshot
rofi -e "Screenshot created: $screenshot"
;;
region)
maim --select $screenshot
rofi -e "Screenshot created: $screenshot"
;;
*)
echo "Error! Invalid mode. Use screenshot.sh full|region "
;;
esac
else
echo "Unknown OS"
exit 2
fi

View file

@ -0,0 +1,12 @@
#!/usr/bin/env sh
connected_monitors=$(xrandr | grep " connected" | awk '{ print $1 }')
if echo "$connected_monitors" | grep -q "HDMI"; then
xrandr --output eDP-1 --off
xrandr --output HDMI-1-0 --mode 2560x1440 --rate 165.00 --dpi 120
# xrandr --output eDP-1 --left-of HDMI-1-0
xrandr --output HDMI-1-0 --primary
else
xrandr --output eDP-1 --mode 2560x1600 --rate 240.00 --dpi 160
fi

View file

@ -54,7 +54,7 @@ opensnitch-ui &
setxkbmap -layout us,ru -option 'grp:alt_space_toggle'
# lockscreen
xss-lock --transfer-sleep-lock -- i3lock --nofork
# xss-lock --transfer-sleep-lock -- ~/scripts/bin/lock.sh
# archive commands
# xinput --set-prop "pointer:Logitech MX Ergo Multi-Device Trackball " 'libinput Accel Speed' -0.2

View file

@ -28,8 +28,8 @@ font pango:monospace 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 --nofork
exec --no-startup-id xss-lock -- ~/.config/i3/i3lock --nofork
exec --no-startup-id xss-lock --transfer-sleep-lock -- ~/scripts/bin/lock.sh
#exec --no-startup-id xss-lock -- ~/scripts/bin/lock.sh
# Use pactl to adjust volume in PulseAudio.
# set $refresh_i3status killall -SIGUSR1 i3status
@ -172,7 +172,7 @@ bindsym $mod+Shift+r restart
# exit i3 (logs you out of your X session)
bindsym $mod+Shift+e exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -B 'Yes, exit i3' 'i3-msg exit'"
# i3lock
bindsym $mod+Shift+x exec --no-startup-id ~/.config/i3/i3lock
bindsym $mod+Shift+x exec --no-startup-id ~/scripts/bin/lock.sh &
# screen
bindsym $mod+Control+s exec --no-startup-id ~/scripts/bin/screenshot.sh region
bindsym $mod+Control+f exec --no-startup-id ~/scripts/bin/screenshot.sh full

View file

@ -8,29 +8,30 @@ WRONG='#880000bb'
VERIFYING='#00564dE6'
i3lock \
--insidever-color=$CLEAR \
--ringver-color=$VERIFYING \
\
--insidewrong-color=$CLEAR \
--ringwrong-color=$WRONG \
\
--inside-color=$BLANK \
--ring-color=$DEFAULT \
--line-color=$BLANK \
--separator-color=$DEFAULT \
\
--verif-color=$TEXT \
--wrong-color=$TEXT \
--time-color=$TEXT \
--date-color=$TEXT \
--layout-color=$TEXT \
--keyhl-color=$WRONG \
--bshl-color=$WRONG \
\
--screen 1 \
--blur 9 \
--clock \
--indicator \
--time-str="%H:%M:%S" \
--date-str="%A, %Y-%m-%d" \
--keylayout 1 \
--insidever-color=$CLEAR \
--ringver-color=$VERIFYING \
\
--insidewrong-color=$CLEAR \
--ringwrong-color=$WRONG \
\
--inside-color=$BLANK \
--ring-color=$DEFAULT \
--line-color=$BLANK \
--separator-color=$DEFAULT \
\
--verif-color=$TEXT \
--wrong-color=$TEXT \
--time-color=$TEXT \
--date-color=$TEXT \
--layout-color=$TEXT \
--keyhl-color=$WRONG \
--bshl-color=$WRONG \
\
--screen 1 \
--blur 9 \
--clock \
--indicator \
--time-str="%H:%M:%S" \
--date-str="%A, %Y-%m-%d" \
--keylayout 1 \
-n

View file

@ -13,7 +13,7 @@
divert-keys: {82: 0, 83: 0, 86: 0, 91: 0, 93: 0, 237: 0}
lowres-scroll-mode: false
persistent-remappable-keys: null
pointer_speed: 180
pointer_speed: 190
reprogrammable-keys: {80: 80, 81: 81, 82: 82, 83: 83, 86: 86, 91: 91, 93: 93, 237: 237}
speed-change: 0
- _NAME: 'MX Ergo Multi-Device Trackball '
@ -52,6 +52,7 @@
adc_power_management]
_battery: 4096
_modelId: 'MX Ergo Multi-Device Trackball '
_sensitive: {hires-scroll-mode: ignore, hires-smooth-invert: ignore, hires-smooth-resolution: ignore}
change-host: null
divert-keys: {82: 0, 83: 0, 86: 0, 91: 0, 93: 0, 237: 0}
lowres-scroll-mode: false

View file

@ -13,7 +13,7 @@ port 465
tls_starttls off
from foozzione@gmail.com
user foozzione@gmail.com
passwordeval "gpg -dq $HOME/.config/mutt/gmail_isync.gpg"
passwordeval "gpg -dq --for-your-eyes-only $HOME/.config/mutt/gmail_isync.gpg"
# Posteo
account posteo
@ -22,7 +22,7 @@ port 465
tls_starttls off
from fz0x1@posteo.net
user fz0x1@posteo.net
passwordeval "gpg -dq $HOME/.config/mutt/posteo_isync.gpg"
passwordeval "gpg -dq --for-your-eyes-only $HOME/.config/mutt/posteo_isync.gpg"
# Set a default account
account default: posteo

View file

@ -3,7 +3,7 @@ alias zup='sudo zypper dup'
alias zin='sudo zypper in'
alias rbf='sudo systemctl reboot --firmware-setup'
## Arch Linux
alias sleep='systemctl suspend'
alias ossleep='systemctl suspend'
alias yyu='sudo pacman -Syyu'
## xsel
alias cop='xsel --clipboard --input'