summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkkard2 <[email protected]>2025-10-30 14:08:15 +0100
committerkkard2 <[email protected]>2026-03-07 14:21:55 +0100
commit3ec7bf19b2be910ee28a89da9487c9725d86fe24 (patch)
treee5b6807a8ea281745a439a2128212e160520ae60
parenta1b2c814e43161401889d7e0abdea2f46c7ed0ef (diff)
i use linux btw
-rw-r--r--_linux/hypr/hyprland.conf6
-rw-r--r--_linux/i3/config3
-rwxr-xr-x_linux/scripts/flash_kb.sh55
-rwxr-xr-x_linux/scripts/mcsr.sh23
-rwxr-xr-x_linux/sxhkd/boateye.sh29
-rw-r--r--_linux/sxhkd/sxhkdrc18
-rw-r--r--kanata/.gitignore1
-rw-r--r--kanata/artseyio.kbd95
-rwxr-xr-xkanata/chords.py37
-rw-r--r--kanata/kanata.kbd44
-rw-r--r--kanata/one.kbd106
11 files changed, 112 insertions, 305 deletions
diff --git a/_linux/hypr/hyprland.conf b/_linux/hypr/hyprland.conf
index df146d5..9b3aa03 100644
--- a/_linux/hypr/hyprland.conf
+++ b/_linux/hypr/hyprland.conf
@@ -13,9 +13,9 @@ exec-once = copyq
exec-once = /home/kkard2/soft/espanso-thing
# Set programs that you use
-$terminal = kitty
-$fileManager = dolphin
-$menu = wofi --show drun
+$terminal = st -f "Noto Sans Mono:style=Regular:size=12" -e tmux
+$fileManager = thunar
+$menu = dmenu_run
# Some default env vars.
env = XCURSOR_SIZE,24
diff --git a/_linux/i3/config b/_linux/i3/config
index eddc6a3..0f9a639 100644
--- a/_linux/i3/config
+++ b/_linux/i3/config
@@ -113,9 +113,6 @@ bindsym $mod+e layout toggle split
# toggle tiling / floating
bindsym $mod+space floating toggle
-# boateye mentioned? (i'm still not hitting it)
-bindsym $mod+g fullscreen toggle; floating toggle ; resize set 384 16384 ; move position center
-
# change focus between tiling / floating windows
# bindsym $mod+space focus mode_toggle
diff --git a/_linux/scripts/flash_kb.sh b/_linux/scripts/flash_kb.sh
new file mode 100755
index 0000000..57d5a92
--- /dev/null
+++ b/_linux/scripts/flash_kb.sh
@@ -0,0 +1,55 @@
+#!/usr/bin/env bash
+set -euo pipefail
+
+FIRMWARE="$1"
+
+if [[ ! -f "$FIRMWARE" ]]; then
+ echo "❌ Firmware file not found: $FIRMWARE"
+ exit 1
+fi
+
+# Ask for sudo upfront
+sudo -v
+# Keep-alive: update existing sudo timestamp until script finishes
+while true; do sudo -n true; sleep 60; kill -0 "$$" || exit; done 2>/dev/null &
+
+declare -A LABELS=( ["left"]="GLV80LHBOOT" ["right"]="GLV80RHBOOT" )
+declare -A MOUNTPOINTS=( ["left"]="/mnt/kb_left" ["right"]="/mnt/kb_right" )
+
+flash_half() {
+ local side="$1"
+ local label="${LABELS[$side]}"
+ local mount_point="${MOUNTPOINTS[$side]}"
+
+ echo ""
+ echo "⚙️ Waiting for $side half ($label) to appear in bootloader mode..."
+
+ # Wait until device with correct label appears
+ while true; do
+ DEV=$(lsblk -o NAME,LABEL,PATH -nr | awk -v lbl="$label" '$2 == lbl {print $3}' || true)
+ if [[ -n "$DEV" ]]; then
+ echo "✅ Found $side half at $DEV"
+ break
+ fi
+ sleep 1
+ done
+
+ sudo mkdir -p "$mount_point"
+ echo "📦 Mounting $DEV to $mount_point..."
+ sudo mount "$DEV" "$mount_point"
+
+ echo "📤 Copying firmware..."
+ sudo cp "$FIRMWARE" "$mount_point"/
+ sync
+
+ echo "💾 Unmounting..."
+ sudo umount "$mount_point"
+
+ echo "✅ $side half flashed successfully!"
+}
+
+flash_half "left"
+flash_half "right"
+
+echo ""
+echo "🎉 Both halves flashed successfully!"
diff --git a/_linux/scripts/mcsr.sh b/_linux/scripts/mcsr.sh
new file mode 100755
index 0000000..89d2136
--- /dev/null
+++ b/_linux/scripts/mcsr.sh
@@ -0,0 +1,23 @@
+#!/bin/bash
+
+pids=()
+
+cleanup() {
+ for pid in "${pids[@]}"; do
+ if kill -0 "$pid" 2>/dev/null; then
+ kill "$pid"
+ fi
+ done
+ exit 1
+}
+
+trap cleanup SIGINT SIGTERM
+
+sxhkd &
+pids+=($!)
+xeyesee &
+pids+=($!)
+nbb &
+pids+=($!)
+
+wait
diff --git a/_linux/sxhkd/boateye.sh b/_linux/sxhkd/boateye.sh
new file mode 100755
index 0000000..070e432
--- /dev/null
+++ b/_linux/sxhkd/boateye.sh
@@ -0,0 +1,29 @@
+#!/bin/bash
+
+zoom_w=300
+zoom_h=16384
+zoom_x=750
+zoom_y=$(( (900 - zoom_h) / 2 ))
+
+normal_w=1600
+normal_h=900
+normal_x=0
+normal_y=0
+
+normal_multiplier=0.25
+zoom_multiplier=0.03125
+device_id="E-Signal USB Gaming Mouse"
+
+# Get active window info
+eval "$(xdotool getactivewindow getwindowgeometry --shell)"
+title="$(xdotool getactivewindow getwindowname)"
+
+if [[ "$title" == *"Minecraft"* && "$HEIGHT" -eq "$normal_h" ]]; then
+ wmctrl -r ":ACTIVE:" -e "0,${zoom_x},${zoom_y},${zoom_w},${zoom_h}"
+ xinput set-prop "$device_id" 'Coordinate Transformation Matrix' \
+ $zoom_multiplier 0 0 0 $zoom_multiplier 0 0 0 1
+else
+ wmctrl -r ":ACTIVE:" -e "0,${normal_x},${normal_y},${normal_w},${normal_h}"
+ xinput set-prop "$device_id" 'Coordinate Transformation Matrix' \
+ $normal_multiplier 0 0 0 $normal_multiplier 0 0 0 1
+fi
diff --git a/_linux/sxhkd/sxhkdrc b/_linux/sxhkd/sxhkdrc
index 5035c74..1898bac 100644
--- a/_linux/sxhkd/sxhkdrc
+++ b/_linux/sxhkd/sxhkdrc
@@ -1,16 +1,2 @@
-super + shift + s
- flameshot gui
-super + w
- firefox
-
-super + ctrl + Up
- pactl set-sink-volume @DEFAULT_SINK@ +5% && $refresh_i3status
-super + ctrl + Down
- pactl set-sink-volume @DEFAULT_SINK@ -5% && $refresh_i3status
-super + shift + m
- pactl set-source-mute @DEFAULT_SOURCE@ toggle && $refresh_i3status
-super + ctrl + space
- playerctl play-pause
-
-super + v
- copyq toggle
+m
+ ~/.config/sxhkd/boateye.sh
diff --git a/kanata/.gitignore b/kanata/.gitignore
deleted file mode 100644
index cf08c3a..0000000
--- a/kanata/.gitignore
+++ /dev/null
@@ -1 +0,0 @@
-chords.kbd
diff --git a/kanata/artseyio.kbd b/kanata/artseyio.kbd
deleted file mode 100644
index c891c93..0000000
--- a/kanata/artseyio.kbd
+++ /dev/null
@@ -1,95 +0,0 @@
-(defcfg
- process-unmapped-keys yes
- concurrent-tap-hold yes
-)
-
-(defsrc
- u i o p
- j k l ;
-
- NumpadDivide
- NumpadMultiply
-)
-
-(deflayer default
- a r t s
- e y i o
-
- (layer-switch default)
- (layer-switch gaming)
-)
-
-(deflayer nav
- home up end pgup
- left down rght pgdn
-
- (layer-switch default)
- (layer-switch gaming)
-)
-
-(deflayer gaming
- _ _ _ _
- _ _ _ _
-
- (layer-switch default)
- (layer-switch gaming)
-)
-
-(defvar
- combo-term 60
- a u
- r i
- t o
- s p
-
- e j
- y k
- i l
- o ;
-)
-
-;; TODO(kk): replace with 2 line style
-(defchordsv2
- ($e $o) b $combo-term first-release (gaming)
- ($e $y ) c $combo-term first-release (gaming)
- ($a $r $t ) d $combo-term first-release (gaming)
- ($a $r ) f $combo-term first-release (gaming)
- ( $r $t ) g $combo-term first-release (gaming)
- ($e $i ) h $combo-term first-release (gaming)
- ( $t $s) j $combo-term first-release (gaming)
- ( $y $o) k $combo-term first-release (gaming)
- ($e $y $i ) l $combo-term first-release (gaming)
- ( $y $i $o) m $combo-term first-release (gaming)
- ( $i $o) n $combo-term first-release (gaming)
- ($e $i $o) p $combo-term first-release (gaming)
- ($a $t $s) q $combo-term first-release (gaming)
- ( $y $i ) u $combo-term first-release (gaming)
- ( $r $s) v $combo-term first-release (gaming)
- ($a $s) w $combo-term first-release (gaming)
- ( $r $t $s) x $combo-term first-release (gaming)
- ($a $r $t $s) z $combo-term first-release (gaming)
-
- ($a
- $e ) ret $combo-term first-release (gaming)
-
- ($a
- $y $i ) (unicode "'") $combo-term first-release (gaming)
- ($a
- $y ) (unicode ".") $combo-term first-release (gaming)
- ($a
- $i ) (unicode ",") $combo-term first-release (gaming)
- ($a
- $o) (unicode "/") $combo-term first-release (gaming)
- ( $t
- $i ) (unicode "!") $combo-term first-release (gaming)
- (
- $e $y $i $o) spc $combo-term first-release (gaming)
- ( $r
- $e ) bspc $combo-term first-release (gaming)
- ( $r
- $i ) bspc $combo-term first-release (gaming)
- ($a $r
- $o) esc $combo-term first-release (gaming)
- ($a $r $t
- $o) tab $combo-term first-release (gaming)
-)
diff --git a/kanata/chords.py b/kanata/chords.py
deleted file mode 100755
index b61dd64..0000000
--- a/kanata/chords.py
+++ /dev/null
@@ -1,37 +0,0 @@
-#!/bin/python
-
-chord_data = {
- "praw": "prawdopodobnie",
- "pro": "probably",
- "com": "co masz na myśli",
- "spr": "sprawiedliwe",
- "spa": "spać mi się chce",
-}
-
-output = "(defchordsv2-experimental\n"
-
-for keys, macro in chord_data.items():
- keys_formatted = " ".join(keys)
- first_char_macro = macro[0]
-
- # The rest of the macro characters are used in (unshift x)
- macro_formatted = ""
-
- for char in macro[1:]:
- if char == " ":
- macro_formatted += "(unshift spc) "
- else:
- macro_formatted += f"(unicode {char}) "
-
- macro_formatted = macro_formatted.strip()
- release = "first-release"
-
- chord_line = f" ({keys_formatted}) (macro {first_char_macro} {
- macro_formatted}) 75 {release} (gaming)\n"
- output += chord_line
-
-output += ")\n"
-
-file = open("chords.kbd", "w")
-file.write(output)
-file.close()
diff --git a/kanata/kanata.kbd b/kanata/kanata.kbd
index 7820585..d9d2794 100644
--- a/kanata/kanata.kbd
+++ b/kanata/kanata.kbd
@@ -9,56 +9,12 @@
caps a s d f g h j k l ; ' ret
lsft z x c v b n m , . / rsft
lctl lmet lalt spc ralt rmet rctl
-
- NumpadSubtract
- NumpadMultiply
)
(deflayer default
_ _ _ _ _ _ _ _ _ _ _ _ _ _
- @tab _ _ _ _ _ _ _ _ _ _ _ _ _
- @ctl _ _ _ _ _ _ _ _ _ _ _ _
- _ _ _ _ _ _ _ _ _ _ _ _
- _ _ _ _ _ _ _
-
- (layer-switch default)
- (layer-switch gaming)
-)
-
-(deflayer gaming
- _ _ _ _ _ _ _ _ _ _ _ _ _ _
_ _ _ _ _ _ _ _ _ _ _ _ _ _
esc _ _ _ _ _ _ _ _ _ _ _ _
_ _ _ _ _ _ _ _ _ _ _ _
_ _ _ _ _ _ _
-
- (layer-switch default)
- (layer-switch gaming)
-)
-
-(deflayer ctllayer
- _ _ _ _ _ _ _ _ _ _ _ _ _ _
- _ _ _ _ _ _ _ _ _ _ _ _ _ esc
- _ _ _ _ _ _ _ _ _ _ _ _ _
- _ _ _ _ _ _ _ _ _ _ _ _
- _ _ _ _ _ _ _
-
- _
- _
-)
-
-(deflayer tablayer
- _ _ _ _ _ _ _ _ _ _ _ _ _ _
- _ _ _ _ _ _ _ _ _ _ _ _ _ _
- _ _ _ _ _ _ left down up rght _ _ _
- _ _ _ _ _ _ _ _ _ _ _ _
- _ _ _ _ _ _ _
-
- _
- _
-)
-
-(defalias
- ctl (multi lctrl (layer-while-held ctllayer))
- tab (tap-hold-press 200 200 tab (layer-toggle tablayer))
)
diff --git a/kanata/one.kbd b/kanata/one.kbd
deleted file mode 100644
index 40259fa..0000000
--- a/kanata/one.kbd
+++ /dev/null
@@ -1,106 +0,0 @@
-(defcfg
- process-unmapped-keys yes
- concurrent-tap-hold yes
-)
-
-(defsrc
- grv 1 2 3 4 5 6 7 8 9 0 - = bspc
- tab q w e r t y u i o p [ ] \
- caps a s d f g h j k l ; ' ret
- lsft z x c v b n m , . / rsft
- lctl lmet lalt spc ralt rmet rctl
-
- NumpadDivide
- NumpadMultiply
-)
-
-(deflayer default
- _ _ _ _ _ _ _ _ _ _ _ _ _ _
- _ esc f d n i g _ _ _ _ _ _ _
- _ bspc s t h e o _ _ _ _ _ _
- _ lsft c w r a u _ _ _ _ _
- _ _ _ _ _ _ _
-
- (layer-switch default)
- (layer-switch gaming)
-)
-
-(deflayer gaming
- _ _ _ _ _ _ _ _ _ _ _ _ _ _
- _ _ _ _ _ _ _ _ _ _ _ _ _ _
- @cap _ _ _ _ _ _ _ _ _ _ _ _
- _ _ _ _ _ _ _ _ _ _ _ _
- _ _ _ _ _ _ _
-
- (layer-switch default)
- (layer-switch gaming)
-)
-
-(deflayer arrows
- _ _ _ _ _ _ _ _ _ _ _ _ _ _
- _ _ _ _ _ _ _ _ _ _ _ _ _ _
- _ _ _ _ _ _ left down up rght _ _ _
- _ _ _ _ _ _ _ _ _ _ _ _
- _ _ _ _ _ _ _
-
- _
- _
-)
-
-(defalias
- cap (tap-hold-press 200 200 esc (layer-toggle arrows))
- lp (unicode "(")
- rp (unicode ")")
- at (unicode "@")
- car (unicode "^")
- col (unicode ":")
-)
-
-(defvar
- combo-term 60
-)
-
-(defchordsv2
- (spc q) ret $combo-term first-release (gaming)
- (spc w) j $combo-term first-release (gaming)
- (spc e) k $combo-term first-release (gaming)
- (spc r) m $combo-term first-release (gaming)
- (spc t) ' $combo-term first-release (gaming)
- (spc y) - $combo-term first-release (gaming)
-
- ;;(spc a) nop0 $combo-term first-release (gaming)
- (spc s) y $combo-term first-release (gaming)
- (spc d) p $combo-term first-release (gaming)
- (spc f) l $combo-term first-release (gaming)
- (spc g) . $combo-term first-release (gaming)
- (spc h) q $combo-term first-release (gaming)
-
- ;;(spc z) nop0 $combo-term first-release (gaming)
- (spc x) x $combo-term first-release (gaming)
- (spc c) b $combo-term first-release (gaming)
- (spc v) v $combo-term first-release (gaming)
- (spc b) , $combo-term first-release (gaming)
- (spc n) z $combo-term first-release (gaming)
-
-
- (lalt q) tab $combo-term first-release (gaming)
- (lalt w) [ $combo-term first-release (gaming)
- (lalt e) { $combo-term first-release (gaming)
- (lalt r) (unicode "(") $combo-term first-release (gaming)
- (lalt t) (unicode "@") $combo-term first-release (gaming)
- (lalt y) (unicode "^") $combo-term first-release (gaming)
-
- (lalt a) \ $combo-term first-release (gaming)
- (lalt s) (unicode ":") $combo-term first-release (gaming)
- (lalt d) (unicode ";") $combo-term first-release (gaming)
- (lalt f) (unicode "?") $combo-term first-release (gaming)
- (lalt g) (unicode "!") $combo-term first-release (gaming)
- (lalt h) (unicode "/") $combo-term first-release (gaming)
-
- (lalt z) (unicode "~") $combo-term first-release (gaming)
- (lalt x) ] $combo-term first-release (gaming)
- (lalt c) } $combo-term first-release (gaming)
- (lalt v) (unicode ")") $combo-term first-release (gaming)
- (lalt b) (unicode "&") $combo-term first-release (gaming)
- (lalt n) (unicode "*") $combo-term first-release (gaming)
-)