mirror of
https://github.com/thegeneralist01/config.git
synced 2026-07-22 03:15:27 +02:00
Compare commits
4 commits
7bf3bd5c8a
...
9e366fe80b
| Author | SHA1 | Date | |
|---|---|---|---|
| 9e366fe80b | |||
| 7fd352124e | |||
| e9ca3daa19 | |||
| eb40bafb6d |
2 changed files with 51 additions and 10 deletions
|
|
@ -68,7 +68,8 @@ let
|
||||||
]) numbers
|
]) numbers
|
||||||
);
|
);
|
||||||
|
|
||||||
simple_modifications = [
|
# Swap Fn/Globe and left Control only on the built-in keyboard.
|
||||||
|
builtinKeyboardSimpleModifications = [
|
||||||
{
|
{
|
||||||
from.apple_vendor_top_case_key_code = "keyboard_fn";
|
from.apple_vendor_top_case_key_code = "keyboard_fn";
|
||||||
to = [ { key_code = "left_control"; } ];
|
to = [ { key_code = "left_control"; } ];
|
||||||
|
|
@ -85,6 +86,7 @@ let
|
||||||
is_keyboard = true;
|
is_keyboard = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# Swap the G213's Windows/Alt modifiers.
|
||||||
logitechG213SimpleModifications = [
|
logitechG213SimpleModifications = [
|
||||||
{
|
{
|
||||||
from.key_code = "left_command";
|
from.key_code = "left_command";
|
||||||
|
|
@ -96,6 +98,38 @@ let
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
|
||||||
|
logitechMouseIdentifiers = {
|
||||||
|
vendor_id = 1133;
|
||||||
|
product_id = 50503;
|
||||||
|
is_pointing_device = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
# Middle click sends Fn; side buttons navigate back and forward.
|
||||||
|
logitechMouseSimpleModifications = [
|
||||||
|
{
|
||||||
|
from.pointing_button = "button3";
|
||||||
|
to = [ { apple_vendor_top_case_key_code = "keyboard_fn"; } ];
|
||||||
|
}
|
||||||
|
{
|
||||||
|
from.pointing_button = "button4";
|
||||||
|
to = [
|
||||||
|
{
|
||||||
|
key_code = "open_bracket";
|
||||||
|
modifiers = [ "left_command" ];
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
||||||
|
{
|
||||||
|
from.pointing_button = "button5";
|
||||||
|
to = [
|
||||||
|
{
|
||||||
|
key_code = "close_bracket";
|
||||||
|
modifiers = [ "left_command" ];
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
||||||
|
];
|
||||||
|
|
||||||
complex_modifications = {
|
complex_modifications = {
|
||||||
name = "Complex Modifications";
|
name = "Complex Modifications";
|
||||||
rules = [
|
rules = [
|
||||||
|
|
@ -319,16 +353,24 @@ let
|
||||||
name = "default";
|
name = "default";
|
||||||
selected = true;
|
selected = true;
|
||||||
virtual_hid_keyboard.keyboard_type_v2 = "ansi";
|
virtual_hid_keyboard.keyboard_type_v2 = "ansi";
|
||||||
inherit simple_modifications;
|
|
||||||
inherit complex_modifications;
|
inherit complex_modifications;
|
||||||
|
|
||||||
devices = [
|
devices = [
|
||||||
|
{
|
||||||
|
identifiers = {
|
||||||
|
is_keyboard = true;
|
||||||
|
is_built_in_keyboard = true;
|
||||||
|
};
|
||||||
|
simple_modifications = builtinKeyboardSimpleModifications;
|
||||||
|
}
|
||||||
{
|
{
|
||||||
identifiers = logitechG213Identifiers;
|
identifiers = logitechG213Identifiers;
|
||||||
simple_modifications = logitechG213SimpleModifications;
|
simple_modifications = logitechG213SimpleModifications;
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
identifiers.is_keyboard = true;
|
identifiers = logitechMouseIdentifiers;
|
||||||
|
ignore = false;
|
||||||
|
simple_modifications = logitechMouseSimpleModifications;
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,14 +1,13 @@
|
||||||
{ config, lib, ... }: let
|
{ config, lib, ... }: let
|
||||||
inherit (lib) mkIf concatStringsSep;
|
inherit (lib) mkIf;
|
||||||
in {
|
in {
|
||||||
services.resolved = mkIf (!config.isServer) {
|
services.resolved = mkIf (!config.isServer) {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
||||||
extraConfig = config.dnsServers
|
settings.Resolve = {
|
||||||
|> map (server: "DNS=${server}")
|
DNS = config.dnsServers;
|
||||||
|> concatStringsSep "\n";
|
DNSSEC = true;
|
||||||
|
DNSOverTLS = true;
|
||||||
dnssec = "true";
|
};
|
||||||
dnsovertls = "true";
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue