mirror of
https://github.com/tomasriveral/nixos.git
synced 2026-08-12 10:30:44 +02:00
repaired tomato's windowrule and did some keybinds
This commit is contained in:
@@ -12,6 +12,7 @@
|
||||
#../../modules/nixos/ly.nix
|
||||
../../modules/nixos/lyminimal.nix
|
||||
../../modules/nixos/anki.nix
|
||||
../../modules/nixos/udevsimple.nix
|
||||
];
|
||||
|
||||
home-manager = {
|
||||
@@ -188,6 +189,10 @@ vial # Open-source GUI and QMK fork for configuring your keyboard in real time
|
||||
mplayer # Movie player that supports many video formats
|
||||
chromium # used only to flash the firmware on my framework laptop 16 (keyboard.frame.work) as only chromium based browser support webHID.
|
||||
capitaine-cursors-themed # cursor theme
|
||||
usbutils # used for lsusb
|
||||
# used for the framework 16 laptop
|
||||
framework-tool
|
||||
framework-tool-tui
|
||||
];
|
||||
|
||||
# fonts
|
||||
|
||||
@@ -73,14 +73,6 @@ in
|
||||
# █▄▀ █▀▀ █▄█ █▄▄ █ █▄░█ █▀▄ █ █▄░█ █▀▀ █▀
|
||||
# █░█ ██▄ ░█░ █▄█ █ █░▀█ █▄▀ █ █░▀█ █▄█ ▄█
|
||||
# binds to do
|
||||
# when librewolf setup put $browser as librewolf
|
||||
# with framework 16 rgb keypad
|
||||
# exec a little kitty floating window with tomato executed (pomodoro app)
|
||||
# exec the hyprpicker -> copy
|
||||
# if hyprexpo plugin enabled bind = $mainMod, Space, hyprexpo:expo, toggle
|
||||
#bind = Ctrl+$mainMod, 1, exec, pgrep -x ollama > /dev/null || ollama serve & notify-send -u normal -t 3000 "Running Deepseek-r1 with 1.5b parameters" "" & kitty -e sh -c "ollama run deepseek-r1:1.5b"
|
||||
#bind = Ctrl+$mainMod, 2, exec, pgrep -x ollama > /dev/null || ollama serve & notify-send -u normal -t 3000 "Running Deepseek-r1 with 8b parameters" "" & kitty -e sh -c "ollama run deepseek-r1:8b"
|
||||
# exec custom-performance
|
||||
|
||||
bind = [
|
||||
#hyprland/utility keybindings
|
||||
@@ -144,17 +136,24 @@ in
|
||||
", F11, exec, hyprshot -m output"
|
||||
"$mod_SHIFT, S, exec, hyprshot -m region --clipboard only"
|
||||
# framework 16 rgb macropad
|
||||
#"$mod, P, exec, swaync-client -t" # bugs the SUPER key.
|
||||
"Ctrl+$mod, 3, exec, pavucontrol"
|
||||
"Ctrl+$mod, 5, exec, gnome-characters"
|
||||
"Ctrl+$mod, 6, exec, custom-killall"
|
||||
# reloads the autostart programs
|
||||
"Ctrl+Alt, 1, exec, swaync-client -t" # pos 4 1
|
||||
"Ctrl+$mod, 3, exec, pavucontrol" # pos 1 3
|
||||
"Ctrl+$mod, 5, exec, gnome-characters" # pos 2 3
|
||||
"Ctrl+$mod, 6, exec, custom-killall" # pos 1 1
|
||||
# reloads the autostart programs # pos 3 1
|
||||
"Ctrl+$mod, 4, exec, sleep 1 && kitty -o font_size=16 -e sh -c 'custom-weather'"
|
||||
"Ctrl+$mod, 4, exec, sleep 1 && kitty -o font_size=11 -e sh -c 'custom-cowsay'"
|
||||
"Ctrl+$mod, 4, exec, kitty -e 'custom-launch'"
|
||||
"Ctrl+$mod, 4, exec, sleep 1 && kitty -o font_size=5 -e btm --theme gruvbox --disable-click --disable_advanced_kill --enable_cache_memory -g -R -T "
|
||||
"Ctrl+$mod, 4, exec, sleep 1 && kitty -o font_size=1 -e sh -c 'cmatrix -br'"
|
||||
#plugins keybindings
|
||||
# exec a little kitty floating window with tomato executed (pomodoro app)
|
||||
# exec the hyprpicker -> copy
|
||||
# if hyprexpo plugin enabled bind = $mainMod, Space, hyprexpo:expo, toggle
|
||||
#bind = Ctrl+$mainMod, 1, exec, pgrep -x ollama > /dev/null || ollama serve & notify-send -u normal -t 3000 "Running Deepseek-r1 with 1.5b parameters" "" & kitty -e sh -c "ollama run deepseek-r1:1.5b"
|
||||
#bind = Ctrl+$mainMod, 2, exec, pgrep -x ollama > /dev/null || ollama serve & notify-send -u normal -t 3000 "Running Deepseek-r1 with 8b parameters" "" & kitty -e sh -c "ollama run deepseek-r1:8b"
|
||||
# exec custom-performance
|
||||
|
||||
#plugins keybindings
|
||||
#"$mod, SPACE, overview:toggle, "
|
||||
|
||||
];
|
||||
@@ -414,7 +413,7 @@ in
|
||||
"float on, match:class ^(vlc)$"
|
||||
"float on, match:class ^(eog)$"
|
||||
"float on, size 400 175, match:class ^(custom-librewolfprofiles)$"
|
||||
"float on, size 600 600, match:initial_title ^(custom-pomodoro)$"
|
||||
"float on, size 600 600, match:initial_class ^(custom-pomodoro)$"
|
||||
"border_size 0, match:float 0, match:workspace w[tv1]"
|
||||
"rounding 0, match:float 0, match:workspace w[tv1]"
|
||||
"border_size 0, match:float 0, match:workspace f[1]"
|
||||
|
||||
@@ -0,0 +1,136 @@
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
# udev are setup for controlling the framework 16 laptop's keyboard
|
||||
services.udev.extraRules = ''
|
||||
## https://github.com/qmk/qmk_firmware/blob/master/util/udev/50-qmk.extraRules
|
||||
## Atmel DFU
|
||||
#### ATmega16U2
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2fef", TAG+="uaccess"
|
||||
#### ATmega32U2
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ff0", TAG+="uaccess"
|
||||
#### ATmega16U4
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ff3", TAG+="uaccess"
|
||||
#### ATmega32U4
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ff4", TAG+="uaccess"
|
||||
#### AT90USB64
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ff9", TAG+="uaccess"
|
||||
#### AT90USB162
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ffa", TAG+="uaccess"
|
||||
#### AT90USB128
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ffb", TAG+="uaccess"
|
||||
#
|
||||
## Input Club
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1c11", ATTRS{idProduct}=="b007", TAG+="uaccess"
|
||||
#
|
||||
## STM32duino
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1eaf", ATTRS{idProduct}=="0003", TAG+="uaccess"
|
||||
## STM32 DFU
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="0483", ATTRS{idProduct}=="df11", TAG+="uaccess"
|
||||
#
|
||||
## BootloadHID
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="05df", TAG+="uaccess"
|
||||
#
|
||||
## USBAspLoader
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="05dc", TAG+="uaccess"
|
||||
#
|
||||
## USBtinyISP
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1782", ATTRS{idProduct}=="0c9f", TAG+="uaccess"
|
||||
#
|
||||
## ModemManager should ignore the following devices
|
||||
## Atmel SAM-BA (Massdrop)
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="6124", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
|
||||
#
|
||||
## Caterina (Pro Micro)
|
||||
### pid.codes shared PID
|
||||
#### Keyboardio Atreus 2 Bootloader
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1209", ATTRS{idProduct}=="2302", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
|
||||
### Spark Fun Electronics
|
||||
#### Pro Micro 3V3/8MHz
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1b4f", ATTRS{idProduct}=="9203", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
|
||||
#### Pro Micro 5V/16MHz
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1b4f", ATTRS{idProduct}=="9205", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
|
||||
#### LilyPad 3V3/8MHz (and some Pro Micro clones)
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1b4f", ATTRS{idProduct}=="9207", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
|
||||
### Pololu Electronics
|
||||
#### A-Star 32U4
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1ffb", ATTRS{idProduct}=="0101", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
|
||||
### Arduino SA
|
||||
#### Leonardo
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="2341", ATTRS{idProduct}=="0036", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
|
||||
#### Micro
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="2341", ATTRS{idProduct}=="0037", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
|
||||
### Adafruit Industries LLC
|
||||
#### Feather 32U4
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="239a", ATTRS{idProduct}=="000c", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
|
||||
#### ItsyBitsy 32U4 3V3/8MHz
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="239a", ATTRS{idProduct}=="000d", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
|
||||
#### ItsyBitsy 32U4 5V/16MHz
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="239a", ATTRS{idProduct}=="000e", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
|
||||
### dog hunter AG
|
||||
#### Leonardo
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="2a03", ATTRS{idProduct}=="0036", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
|
||||
#### Micro
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="2a03", ATTRS{idProduct}=="0037", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
|
||||
#
|
||||
## hid_listen
|
||||
#KERNEL=="hidraw*", MODE="0660", GROUP="plugdev", TAG+="uaccess", TAG+="udev-acl"
|
||||
#
|
||||
## hid bootloaders
|
||||
### QMK HID
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2067", TAG+="uaccess"
|
||||
### PJRC's HalfKay
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="0478", TAG+="uaccess"
|
||||
#
|
||||
## APM32 DFU
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="314b", ATTRS{idProduct}=="0106", TAG+="uaccess"
|
||||
#
|
||||
## GD32V DFU
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="28e9", ATTRS{idProduct}=="0189", TAG+="uaccess"
|
||||
#
|
||||
## WB32 DFU
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="342d", ATTRS{idProduct}=="dfa0", TAG+="uaccess"
|
||||
#
|
||||
## AT32 DFU
|
||||
# SUBSYSTEMS=="usb", ATTRS{idVendor}=="2e3c", ATTRS{idProduct}=="df11", TAG+="uaccess"
|
||||
|
||||
|
||||
# and # https://community.frame.work/t/guide-updated-after-firmware-updates-udev-rules-for-https-keyboard-frame-work/78708
|
||||
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0010", TAG+="uaccess"
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0012", TAG+="uaccess"
|
||||
SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0013", TAG+="uaccess"
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0014", TAG+="uaccess"
|
||||
SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0018", TAG+="uaccess"
|
||||
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0019", TAG+="uaccess"
|
||||
|
||||
|
||||
|
||||
|
||||
# USB [VendorID]:[ProductID] “[Manufacturer][Product name]”
|
||||
# 32ac:0012 “Framework Laptop 16 Keyboard Module - ANSI”
|
||||
# 32ac:0013 “Framework Laptop 16 RGB Macropad”
|
||||
# 32ac:0014 “Framework Laptop 16 Numpad Module”
|
||||
# 32ac:0018 “Framework Laptop 16 Keyboard Module - ISO”
|
||||
# 32ac:0019 “Framework Laptop 16 Keyboard Module - JIS”
|
||||
|
||||
|
||||
##https://github.com/ublue-os/config/blob/main/files/etc/udev/rules.d/50-framework16.rules
|
||||
## Audio Expansion Card
|
||||
#ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="32ac", ATTR{idProduct}=="0010", ATTR{power/autosuspend}="10", ATTR{power/control}="auto", GOTO="rules_end"
|
||||
#
|
||||
## Framework Laptop 16 Keyboard Module - ANSI
|
||||
#ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="32ac", ATTR{idProduct}=="0012", ATTR{power/autosuspend}="-1", ATTR{power/control}="on", ATTR{power/wakeup}="disabled", GOTO="rules_end"
|
||||
#
|
||||
## Framework Laptop 16 RGB Macropad
|
||||
#
|
||||
## Framework Laptop 16 Numpad Module
|
||||
#ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="32ac", ATTR{idProduct}=="0014", ATTR{power/autosuspend}="-1", ATTR{power/control}="on", ATTR{power/wakeup}="disabled", GOTO="rules_end"
|
||||
#
|
||||
## Framework Laptop 16 Keyboard Module
|
||||
#ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="32ac", ATTR{idProduct}=="0018", ATTR{power/autosuspend}="-1", ATTR{power/control}="on", ATTR{power/wakeup}="disabled", GOTO="rules_end"
|
||||
#
|
||||
#LABEL="rules_end"
|
||||
|
||||
'';
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
# udev with only the necessary rules. See udev.nix to get all the rules
|
||||
services.udev.extraRules = ''
|
||||
# adapted from here https://wiki.nixos.org/wiki/Keychron_M6
|
||||
KERNEL=="hidraw*", SUBSYSTEM=="hidraw", ATTRS{idVendor}=="32ac", MODE="0660", GROUP="users", TAG+="uaccess"
|
||||
|
||||
|
||||
# taken from here
|
||||
SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0013", TAG+="uaccess"
|
||||
SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0018", TAG+="uaccess"
|
||||
'';
|
||||
}
|
||||
@@ -6,9 +6,10 @@ writeShellApplication {
|
||||
hyprland
|
||||
jq
|
||||
];
|
||||
text = ''
|
||||
if [[ $(hyprctl activewindow -j | jq -r ".class") == "Steam" ]]; then
|
||||
hyprctl dispatch minimize
|
||||
text = ''
|
||||
class=$(hyprctl activewindow -j | jq -r ".class")
|
||||
if [[ "$class" == "Steam" || "$class" == "custom-pomodoro" ]]; then
|
||||
hyprctl dispatch movetoworkspacesilent special
|
||||
else
|
||||
hyprctl dispatch killactive ""
|
||||
fi
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
# used for the terminal autostart. Needs to get cleared and recall fastfetch so that the bar from oh-my-zsh get resized
|
||||
|
||||
{ writeShellApplication, kitty, tomato-c,... }:
|
||||
|
||||
writeShellApplication {
|
||||
@@ -9,6 +7,6 @@ writeShellApplication {
|
||||
tomato-c
|
||||
];
|
||||
text = ''
|
||||
kitty --name "custom-pomodoro" -e tomato
|
||||
kitty --class "custom-pomodoro" --name "custom-pomodoro" -e tomato
|
||||
'';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user