nixos configs

darwin: switch from aerospace to PaperWM

+440 -334
+268 -30
flake.lock
··· 1 1 { 2 2 "nodes": { 3 + "OS-nixCfg": { 4 + "flake": false, 5 + "locked": { 6 + "lastModified": 1769083382, 7 + "narHash": "sha256-Six3xqrcu4BkIwyAscSwKdJJKiE5Rzyvuq6pDHMxnLs=", 8 + "owner": "DivitMittal", 9 + "repo": "OS-nixCfg", 10 + "rev": "ffe5286ceee9ae65728a49cd9f97e3a7d6951f15", 11 + "type": "github" 12 + }, 13 + "original": { 14 + "owner": "DivitMittal", 15 + "repo": "OS-nixCfg", 16 + "type": "github" 17 + } 18 + }, 19 + "actions-nix": { 20 + "inputs": { 21 + "flake-parts": [ 22 + "hammerspoon-nix", 23 + "flake-parts" 24 + ], 25 + "git-hooks": [ 26 + "hammerspoon-nix", 27 + "git-hooks" 28 + ], 29 + "nixpkgs": [ 30 + "hammerspoon-nix", 31 + "nixpkgs" 32 + ] 33 + }, 34 + "locked": { 35 + "lastModified": 1769595617, 36 + "narHash": "sha256-IPWJKsWDNZnElPuWcL1pF+9M0BJx7bGZI2/rJiqOpBs=", 37 + "owner": "nialov", 38 + "repo": "actions.nix", 39 + "rev": "9c69acded275f52aefa58ce78efc61fa5c11d94c", 40 + "type": "github" 41 + }, 42 + "original": { 43 + "owner": "nialov", 44 + "repo": "actions.nix", 45 + "type": "github" 46 + } 47 + }, 48 + "devshell": { 49 + "inputs": { 50 + "nixpkgs": [ 51 + "hammerspoon-nix", 52 + "nixpkgs" 53 + ] 54 + }, 55 + "locked": { 56 + "lastModified": 1768818222, 57 + "narHash": "sha256-460jc0+CZfyaO8+w8JNtlClB2n4ui1RbHfPTLkpwhU8=", 58 + "owner": "numtide", 59 + "repo": "devshell", 60 + "rev": "255a2b1725a20d060f566e4755dbf571bbbb5f76", 61 + "type": "github" 62 + }, 63 + "original": { 64 + "owner": "numtide", 65 + "repo": "devshell", 66 + "type": "github" 67 + } 68 + }, 3 69 "disko": { 4 70 "inputs": { 5 71 "nixpkgs": [ ··· 46 112 "flake-compat": { 47 113 "flake": false, 48 114 "locked": { 115 + "lastModified": 1767039857, 116 + "narHash": "sha256-vNpUSpF5Nuw8xvDLj2KCwwksIbjua2LZCqhV1LNRDns=", 117 + "owner": "NixOS", 118 + "repo": "flake-compat", 119 + "rev": "5edf11c44bc78a0d334f6334cdaf7d60d732daab", 120 + "type": "github" 121 + }, 122 + "original": { 123 + "owner": "NixOS", 124 + "repo": "flake-compat", 125 + "type": "github" 126 + } 127 + }, 128 + "flake-compat_2": { 129 + "flake": false, 130 + "locked": { 49 131 "lastModified": 1747046372, 50 132 "narHash": "sha256-CIVLLkVgvHYbgI2UpXvIIBJ12HWgX+fjA8Xf8PUmqCY=", 51 133 "owner": "edolstra", ··· 64 146 "nixpkgs-lib": "nixpkgs-lib" 65 147 }, 66 148 "locked": { 149 + "lastModified": 1768135262, 150 + "narHash": "sha256-PVvu7OqHBGWN16zSi6tEmPwwHQ4rLPU9Plvs8/1TUBY=", 151 + "owner": "hercules-ci", 152 + "repo": "flake-parts", 153 + "rev": "80daad04eddbbf5a4d883996a73f3f542fa437ac", 154 + "type": "github" 155 + }, 156 + "original": { 157 + "owner": "hercules-ci", 158 + "repo": "flake-parts", 159 + "type": "github" 160 + } 161 + }, 162 + "flake-parts_2": { 163 + "inputs": { 164 + "nixpkgs-lib": "nixpkgs-lib_2" 165 + }, 166 + "locked": { 67 167 "lastModified": 1762440070, 68 168 "narHash": "sha256-xxdepIcb39UJ94+YydGP221rjnpkDZUlykKuF54PsqI=", 69 169 "owner": "hercules-ci", ··· 77 177 "type": "github" 78 178 } 79 179 }, 80 - "flake-parts_2": { 180 + "flake-parts_3": { 81 181 "inputs": { 82 182 "nixpkgs-lib": [ 83 183 "nixvim", ··· 100 200 }, 101 201 "flake-utils": { 102 202 "inputs": { 103 - "systems": "systems_2" 203 + "systems": "systems_3" 104 204 }, 105 205 "locked": { 106 206 "lastModified": 1731533236, ··· 118 218 }, 119 219 "flake-utils_2": { 120 220 "inputs": { 121 - "systems": "systems_3" 221 + "systems": "systems_4" 122 222 }, 123 223 "locked": { 124 224 "lastModified": 1731533236, ··· 136 236 }, 137 237 "flake-utils_3": { 138 238 "inputs": { 139 - "systems": "systems_5" 239 + "systems": "systems_6" 140 240 }, 141 241 "locked": { 142 242 "lastModified": 1681202837, ··· 152 252 "type": "github" 153 253 } 154 254 }, 255 + "git-hooks": { 256 + "inputs": { 257 + "flake-compat": "flake-compat", 258 + "gitignore": "gitignore", 259 + "nixpkgs": [ 260 + "hammerspoon-nix", 261 + "nixpkgs" 262 + ] 263 + }, 264 + "locked": { 265 + "lastModified": 1769069492, 266 + "narHash": "sha256-Efs3VUPelRduf3PpfPP2ovEB4CXT7vHf8W+xc49RL/U=", 267 + "owner": "cachix", 268 + "repo": "git-hooks.nix", 269 + "rev": "a1ef738813b15cf8ec759bdff5761b027e3e1d23", 270 + "type": "github" 271 + }, 272 + "original": { 273 + "owner": "cachix", 274 + "repo": "git-hooks.nix", 275 + "type": "github" 276 + } 277 + }, 278 + "gitignore": { 279 + "inputs": { 280 + "nixpkgs": [ 281 + "hammerspoon-nix", 282 + "git-hooks", 283 + "nixpkgs" 284 + ] 285 + }, 286 + "locked": { 287 + "lastModified": 1709087332, 288 + "narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=", 289 + "owner": "hercules-ci", 290 + "repo": "gitignore.nix", 291 + "rev": "637db329424fd7e46cf4185293b9cc8c88c95394", 292 + "type": "github" 293 + }, 294 + "original": { 295 + "owner": "hercules-ci", 296 + "repo": "gitignore.nix", 297 + "type": "github" 298 + } 299 + }, 300 + "hammerspoon-nix": { 301 + "inputs": { 302 + "OS-nixCfg": "OS-nixCfg", 303 + "actions-nix": "actions-nix", 304 + "devshell": "devshell", 305 + "flake-parts": "flake-parts", 306 + "git-hooks": "git-hooks", 307 + "nixpkgs": "nixpkgs", 308 + "systems": "systems", 309 + "treefmt-nix": "treefmt-nix" 310 + }, 311 + "locked": { 312 + "lastModified": 1769933483, 313 + "narHash": "sha256-iAz6yYQnmBQksqFBaWWvIOPNLRoYN6BpdLjGV8l2qqI=", 314 + "owner": "DivitMittal", 315 + "repo": "hammerspoon-nix", 316 + "rev": "02d5a05c7c9f418920f5129d47beff9bd1984865", 317 + "type": "github" 318 + }, 319 + "original": { 320 + "owner": "DivitMittal", 321 + "repo": "hammerspoon-nix", 322 + "type": "github" 323 + } 324 + }, 155 325 "home-manager": { 156 326 "inputs": { 157 327 "nixpkgs": [ ··· 174 344 }, 175 345 "minecraft-plymouth-theme": { 176 346 "inputs": { 177 - "flake-parts": "flake-parts", 178 - "nixpkgs": "nixpkgs", 179 - "systems": "systems" 347 + "flake-parts": "flake-parts_2", 348 + "nixpkgs": "nixpkgs_2", 349 + "systems": "systems_2" 180 350 }, 181 351 "locked": { 182 352 "lastModified": 1762860197, ··· 292 462 }, 293 463 "nix-minecraft": { 294 464 "inputs": { 295 - "flake-compat": "flake-compat", 465 + "flake-compat": "flake-compat_2", 296 466 "flake-utils": "flake-utils", 297 467 "nixpkgs": [ 298 468 "nixpkgs" ··· 335 505 }, 336 506 "nixpkgs": { 337 507 "locked": { 338 - "lastModified": 1762363567, 339 - "narHash": "sha256-YRqMDEtSMbitIMj+JLpheSz0pwEr0Rmy5mC7myl17xs=", 508 + "lastModified": 1769740369, 509 + "narHash": "sha256-xKPyJoMoXfXpDM5DFDZDsi9PHArf2k5BJjvReYXoFpM=", 340 510 "owner": "nixos", 341 511 "repo": "nixpkgs", 342 - "rev": "ae814fd3904b621d8ab97418f1d0f2eb0d3716f4", 512 + "rev": "6308c3b21396534d8aaeac46179c14c439a89b8a", 343 513 "type": "github" 344 514 }, 345 515 "original": { 346 516 "owner": "nixos", 347 - "ref": "nixos-unstable", 517 + "ref": "nixpkgs-unstable", 348 518 "repo": "nixpkgs", 349 519 "type": "github" 350 520 } 351 521 }, 352 522 "nixpkgs-lib": { 353 523 "locked": { 524 + "lastModified": 1765674936, 525 + "narHash": "sha256-k00uTP4JNfmejrCLJOwdObYC9jHRrr/5M/a/8L2EIdo=", 526 + "owner": "nix-community", 527 + "repo": "nixpkgs.lib", 528 + "rev": "2075416fcb47225d9b68ac469a5c4801a9c4dd85", 529 + "type": "github" 530 + }, 531 + "original": { 532 + "owner": "nix-community", 533 + "repo": "nixpkgs.lib", 534 + "type": "github" 535 + } 536 + }, 537 + "nixpkgs-lib_2": { 538 + "locked": { 354 539 "lastModified": 1761765539, 355 540 "narHash": "sha256-b0yj6kfvO8ApcSE+QmA6mUfu8IYG6/uU28OFn4PaC8M=", 356 541 "owner": "nix-community", ··· 381 566 } 382 567 }, 383 568 "nixpkgs_2": { 569 + "locked": { 570 + "lastModified": 1762363567, 571 + "narHash": "sha256-YRqMDEtSMbitIMj+JLpheSz0pwEr0Rmy5mC7myl17xs=", 572 + "owner": "nixos", 573 + "repo": "nixpkgs", 574 + "rev": "ae814fd3904b621d8ab97418f1d0f2eb0d3716f4", 575 + "type": "github" 576 + }, 577 + "original": { 578 + "owner": "nixos", 579 + "ref": "nixos-unstable", 580 + "repo": "nixpkgs", 581 + "type": "github" 582 + } 583 + }, 584 + "nixpkgs_3": { 384 585 "locked": { 385 586 "lastModified": 1768564909, 386 587 "narHash": "sha256-Kell/SpJYVkHWMvnhqJz/8DqQg2b6PguxVWOuadbHCc=", ··· 398 599 }, 399 600 "nixvim": { 400 601 "inputs": { 401 - "flake-parts": "flake-parts_2", 602 + "flake-parts": "flake-parts_3", 402 603 "nixpkgs": [ 403 604 "nixpkgs" 404 605 ], 405 - "systems": "systems_4" 606 + "systems": "systems_5" 406 607 }, 407 608 "locked": { 408 609 "lastModified": 1768795384, ··· 442 643 "inputs": { 443 644 "disko": "disko", 444 645 "firefox-addons": "firefox-addons", 646 + "hammerspoon-nix": "hammerspoon-nix", 445 647 "home-manager": "home-manager", 446 648 "minecraft-plymouth-theme": "minecraft-plymouth-theme", 447 649 "minegrub-world-sel-theme": "minegrub-world-sel-theme", ··· 449 651 "nix-darwin": "nix-darwin", 450 652 "nix-minecraft": "nix-minecraft", 451 653 "nixgl": "nixgl", 452 - "nixpkgs": "nixpkgs_2", 654 + "nixpkgs": "nixpkgs_3", 453 655 "nixvim": "nixvim", 454 656 "noctalia": "noctalia", 455 657 "vscode-server": "vscode-server", ··· 458 660 }, 459 661 "systems": { 460 662 "locked": { 461 - "lastModified": 1689347949, 462 - "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", 463 - "owner": "nix-systems", 464 - "repo": "default-linux", 465 - "rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68", 466 - "type": "github" 467 - }, 468 - "original": { 469 - "owner": "nix-systems", 470 - "repo": "default-linux", 663 + "lastModified": 1681028828, 664 + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", 665 + "owner": "nix-systems", 666 + "repo": "default", 667 + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", 668 + "type": "github" 669 + }, 670 + "original": { 671 + "owner": "nix-systems", 672 + "repo": "default", 471 673 "type": "github" 472 674 } 473 675 }, 474 676 "systems_2": { 475 677 "locked": { 476 - "lastModified": 1681028828, 477 - "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", 678 + "lastModified": 1689347949, 679 + "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", 478 680 "owner": "nix-systems", 479 - "repo": "default", 480 - "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", 681 + "repo": "default-linux", 682 + "rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68", 481 683 "type": "github" 482 684 }, 483 685 "original": { 484 686 "owner": "nix-systems", 485 - "repo": "default", 687 + "repo": "default-linux", 486 688 "type": "github" 487 689 } 488 690 }, ··· 528 730 "original": { 529 731 "owner": "nix-systems", 530 732 "repo": "default", 733 + "type": "github" 734 + } 735 + }, 736 + "systems_6": { 737 + "locked": { 738 + "lastModified": 1681028828, 739 + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", 740 + "owner": "nix-systems", 741 + "repo": "default", 742 + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", 743 + "type": "github" 744 + }, 745 + "original": { 746 + "owner": "nix-systems", 747 + "repo": "default", 748 + "type": "github" 749 + } 750 + }, 751 + "treefmt-nix": { 752 + "inputs": { 753 + "nixpkgs": [ 754 + "hammerspoon-nix", 755 + "nixpkgs" 756 + ] 757 + }, 758 + "locked": { 759 + "lastModified": 1769691507, 760 + "narHash": "sha256-8aAYwyVzSSwIhP2glDhw/G0i5+wOrren3v6WmxkVonM=", 761 + "owner": "numtide", 762 + "repo": "treefmt-nix", 763 + "rev": "28b19c5844cc6e2257801d43f2772a4b4c050a1b", 764 + "type": "github" 765 + }, 766 + "original": { 767 + "owner": "numtide", 768 + "repo": "treefmt-nix", 531 769 "type": "github" 532 770 } 533 771 },
+3
flake.nix
··· 48 48 url = "github:sodiboo/niri-flake"; 49 49 inputs.nixpkgs.follows = "nixpkgs"; 50 50 }; 51 + hammerspoon-nix = { 52 + url = "github:DivitMittal/hammerspoon-nix"; 53 + }; 51 54 noctalia = { 52 55 url = "github:noctalia-dev/noctalia-shell"; 53 56 inputs.nixpkgs.follows = "nixpkgs";
-200
home/bates64/gui/aerospace/aerospace.toml
··· 1 - # Place a copy of this config to ~/.aerospace.toml 2 - # After that, you can edit ~/.aerospace.toml to your liking 3 - 4 - # You can use it to add commands that run after login to macOS user session. 5 - # 'start-at-login' needs to be 'true' for 'after-login-command' to work 6 - # Available commands: https://nikitabobko.github.io/AeroSpace/commands 7 - after-login-command = [] 8 - 9 - # You can use it to add commands that run after AeroSpace startup. 10 - # 'after-startup-command' is run after 'after-login-command' 11 - # Available commands : https://nikitabobko.github.io/AeroSpace/commands 12 - after-startup-command = ['exec-and-forget sketchybar'] 13 - 14 - # Notify Sketchybar about workspace change 15 - exec-on-workspace-change = ['/bin/bash', '-c', 16 - 'sketchybar --trigger aerospace_workspace_change FOCUSED_WORKSPACE=$AEROSPACE_FOCUSED_WORKSPACE' 17 - ] 18 - 19 - # Start AeroSpace at login 20 - start-at-login = true 21 - 22 - # Normalizations. See: https://nikitabobko.github.io/AeroSpace/guide#normalization 23 - enable-normalization-flatten-containers = true 24 - enable-normalization-opposite-orientation-for-nested-containers = true 25 - 26 - # See: https://nikitabobko.github.io/AeroSpace/guide#layouts 27 - # The 'accordion-padding' specifies the size of accordion padding 28 - # You can set 0 to disable the padding feature 29 - accordion-padding = 30 30 - 31 - # Possible values: tiles|accordion 32 - default-root-container-layout = 'tiles' 33 - 34 - # Possible values: horizontal|vertical|auto 35 - # 'auto' means: wide monitor (anything wider than high) gets horizontal orientation, 36 - # tall monitor (anything higher than wide) gets vertical orientation 37 - default-root-container-orientation = 'auto' 38 - 39 - # Mouse follows focus when focused monitor changes 40 - # Drop it from your config, if you don't like this behavior 41 - # See https://nikitabobko.github.io/AeroSpace/guide#on-focus-changed-callbacks 42 - # See https://nikitabobko.github.io/AeroSpace/commands#move-mouse 43 - # Fallback value (if you omit the key): on-focused-monitor-changed = [] 44 - on-focused-monitor-changed = ['move-mouse monitor-lazy-center'] 45 - 46 - # You can effectively turn off macOS "Hide application" (cmd-h) feature by toggling this flag 47 - # Useful if you don't use this macOS feature, but accidentally hit cmd-h or cmd-alt-h key 48 - # Also see: https://nikitabobko.github.io/AeroSpace/goodness#disable-hide-app 49 - automatically-unhide-macos-hidden-apps = true 50 - 51 - # Possible values: (qwerty|dvorak) 52 - # See https://nikitabobko.github.io/AeroSpace/guide#key-mapping 53 - [key-mapping] 54 - preset = 'qwerty' 55 - 56 - # Gaps between windows (inner-*) and between monitor edges (outer-*). 57 - # Possible values: 58 - # - Constant: gaps.outer.top = 8 59 - # - Per monitor: gaps.outer.top = [{ monitor.main = 16 }, { monitor."some-pattern" = 32 }, 24] 60 - # In this example, 24 is a default value when there is no match. 61 - # Monitor pattern is the same as for 'workspace-to-monitor-force-assignment'. 62 - # See: https://nikitabobko.github.io/AeroSpace/guide#assign-workspaces-to-monitors 63 - [gaps] 64 - inner.horizontal = 8 65 - inner.vertical = 8 66 - outer.left = 8 67 - outer.bottom = 8 68 - outer.top = 8 69 - outer.right = 8 70 - 71 - # 'main' binding mode declaration 72 - # See: https://nikitabobko.github.io/AeroSpace/guide#binding-modes 73 - # 'main' binding mode must be always presented 74 - # Fallback value (if you omit the key): mode.main.binding = {} 75 - [mode.main.binding] 76 - 77 - # All possible keys: 78 - # - Letters. a, b, c, ..., z 79 - # - Numbers. 0, 1, 2, ..., 9 80 - # - Keypad numbers. keypad0, keypad1, keypad2, ..., keypad9 81 - # - F-keys. f1, f2, ..., f20 82 - # - Special keys. minus, equal, period, comma, slash, backslash, quote, semicolon, backtick, 83 - # leftSquareBracket, rightSquareBracket, space, enter, esc, backspace, tab 84 - # - Keypad special. keypadClear, keypadDecimalMark, keypadDivide, keypadEnter, keypadEqual, 85 - # keypadMinus, keypadMultiply, keypadPlus 86 - # - Arrows. left, down, up, right 87 - 88 - # All possible modifiers: cmd, alt, ctrl, shift 89 - 90 - # All possible commands: https://nikitabobko.github.io/AeroSpace/commands 91 - 92 - # See: https://nikitabobko.github.io/AeroSpace/commands#exec-and-forget 93 - # Open up remote terminal with alt + enter shortcut 94 - alt-enter = 'exec-and-forget wezterm connect arm.pc' 95 - 96 - # See: https://nikitabobko.github.io/AeroSpace/commands#layout 97 - alt-slash = 'layout tiles horizontal vertical' 98 - alt-comma = 'layout accordion horizontal vertical' 99 - 100 - # See: https://nikitabobko.github.io/AeroSpace/commands#focus 101 - alt-h = 'focus left' 102 - alt-j = 'focus down' 103 - alt-k = 'focus up' 104 - alt-l = 'focus right' 105 - 106 - # See: https://nikitabobko.github.io/AeroSpace/commands#move 107 - alt-shift-h = 'move left' 108 - alt-shift-j = 'move down' 109 - alt-shift-k = 'move up' 110 - alt-shift-l = 'move right' 111 - 112 - # See: https://nikitabobko.github.io/AeroSpace/commands#resize 113 - alt-shift-minus = 'resize smart -50' 114 - alt-shift-equal = 'resize smart +50' 115 - 116 - # See: https://nikitabobko.github.io/AeroSpace/commands#workspace 117 - alt-1 = 'workspace 1' 118 - alt-2 = 'workspace 2' 119 - #alt-3 = 'workspace 3' # conflicts with '#' key on GB keyboard 120 - alt-4 = 'workspace 4' 121 - alt-5 = 'workspace 5' 122 - alt-6 = 'workspace 6' 123 - alt-7 = 'workspace 7' 124 - alt-8 = 'workspace 8' 125 - alt-9 = 'workspace 9' 126 - 127 - # See: https://nikitabobko.github.io/AeroSpace/commands#move-node-to-workspace 128 - alt-shift-1 = 'move-node-to-workspace 1' 129 - alt-shift-2 = 'move-node-to-workspace 2' 130 - #alt-shift-3 = 'move-node-to-workspace 3' 131 - alt-shift-4 = 'move-node-to-workspace 4' 132 - alt-shift-5 = 'move-node-to-workspace 5' 133 - alt-shift-6 = 'move-node-to-workspace 6' 134 - alt-shift-7 = 'move-node-to-workspace 7' 135 - alt-shift-8 = 'move-node-to-workspace 8' 136 - alt-shift-9 = 'move-node-to-workspace 9' 137 - 138 - # See: https://nikitabobko.github.io/AeroSpace/commands#workspace-back-and-forth 139 - alt-tab = 'workspace-back-and-forth' 140 - # See: https://nikitabobko.github.io/AeroSpace/commands#move-workspace-to-monitor 141 - alt-shift-tab = 'move-workspace-to-monitor --wrap-around next' 142 - 143 - # See: https://nikitabobko.github.io/AeroSpace/commands#mode 144 - alt-shift-semicolon = 'mode service' 145 - 146 - # 'service' binding mode declaration. 147 - # See: https://nikitabobko.github.io/AeroSpace/guide#binding-modes 148 - [mode.service.binding] 149 - esc = ['reload-config', 'mode main'] 150 - r = ['flatten-workspace-tree', 'mode main'] # reset layout 151 - f = ['layout floating tiling', 'mode main'] # Toggle between floating and tiling layout 152 - backspace = ['close-all-windows-but-current', 'mode main'] 153 - 154 - # sticky is not yet supported https://github.com/nikitabobko/AeroSpace/issues/2 155 - #s = ['layout sticky tiling', 'mode main'] 156 - 157 - alt-shift-h = ['join-with left', 'mode main'] 158 - alt-shift-j = ['join-with down', 'mode main'] 159 - alt-shift-k = ['join-with up', 'mode main'] 160 - alt-shift-l = ['join-with right', 'mode main'] 161 - 162 - [[on-window-detected]] 163 - if.app-id = "com.kagi.kagimacOS" 164 - run = [ "move-node-to-workspace 1" ] 165 - 166 - [[on-window-detected]] 167 - if.app-id = "app.zen-browser.zen" 168 - run = [ "move-node-to-workspace 1" ] 169 - 170 - [[on-window-detected]] 171 - if.app-id = "com.tinyspeck.slackmacgap" 172 - run = [ "move-node-to-workspace 2" ] 173 - 174 - [[on-window-detected]] 175 - if.app-id = "dev.vencord.vesktop" 176 - run = [ "move-node-to-workspace 2" ] 177 - 178 - [[on-window-detected]] 179 - if.app-id = "com.microsoft.VSCode" 180 - run = [ "move-node-to-workspace 4" ] 181 - 182 - [[on-window-detected]] 183 - if.app-id = "md.obsidian" 184 - run = [ "move-node-to-workspace 7" ] 185 - 186 - [[on-window-detected]] 187 - if.app-id = "com.TickTick.task.mac" 188 - run = [ "move-node-to-workspace 8" ] 189 - 190 - [[on-window-detected]] 191 - if.app-id = "com.spotify.client" 192 - run = [ "move-node-to-workspace 9" ] 193 - 194 - [[on-window-detected]] 195 - if.app-id = "com.kagi.kagimacOS.WebApp.758E8559-F3A6-4B80-B34E-901673F85285" # SoundCloud 196 - run = [ "move-node-to-workspace 9" ] 197 - 198 - [[on-window-detected]] 199 - if.window-title-regex-substring = "Cisco Secure Client" 200 - run = [ "layout floating" ]
-20
home/bates64/gui/aerospace/default.nix
··· 1 - { config, lib, pkgs, ... }: { 2 - config = lib.mkIf config.isMacOS { 3 - home.packages = [ pkgs.aerospace pkgs.sketchybar ]; 4 - home.file.".config/aerospace/aerospace.toml".source = ./aerospace.toml; 5 - launchd.agents.aerospace = { 6 - enable = true; 7 - config = { 8 - Program = "${pkgs.aerospace}/Applications/AeroSpace.app/Contents/MacOS/AeroSpace"; 9 - KeepAlive = true; 10 - RunAtLoad = true; 11 - StandardOutPath = "/tmp/aerospace.log"; 12 - StandardErrorPath = "/tmp/aerospace.err.log"; 13 - }; 14 - }; 15 - 16 - home.file.".config/sketchybar/sketchybarrc" = { source = ./sketchybar/sketchybarrc; executable = true; }; 17 - #home.file.".config/sketchybar/plugins".source = ./sketchybar/plugins; 18 - #home.file.".config/sketchybar/plugins".recursive = true; 19 - }; 20 - }
-82
home/bates64/gui/aerospace/sketchybar/sketchybarrc
··· 1 - # This is a demo config to showcase some of the most important commands. 2 - # It is meant to be changed and configured, as it is intentionally kept sparse. 3 - # For a (much) more advanced configuration example see my dotfiles: 4 - # https://github.com/FelixKratz/dotfiles 5 - 6 - PLUGIN_DIR="$CONFIG_DIR/plugins" 7 - 8 - ##### Bar Appearance ##### 9 - # Configuring the general appearance of the bar. 10 - # These are only some of the options available. For all options see: 11 - # https://felixkratz.github.io/SketchyBar/config/bar 12 - # If you are looking for other colors, see the color picker: 13 - # https://felixkratz.github.io/SketchyBar/config/tricks#color-picker 14 - 15 - sketchybar --bar position=top height=38 blur_radius=30 color=0x40000000 16 - 17 - ##### Changing Defaults ##### 18 - # We now change some default values, which are applied to all further items. 19 - # For a full list of all available item properties see: 20 - # https://felixkratz.github.io/SketchyBar/config/items 21 - 22 - default=( 23 - padding_left=5 24 - padding_right=5 25 - icon.font="Hack Nerd Font:Bold:17.0" 26 - label.font="Hack Nerd Font:Bold:14.0" 27 - icon.color=0xffffffff 28 - label.color=0xffffffff 29 - icon.padding_left=4 30 - icon.padding_right=4 31 - label.padding_left=4 32 - label.padding_right=4 33 - ) 34 - sketchybar --default "${default[@]}" 35 - 36 - ##### Aerospace Workspaces ##### 37 - sketchybar --add event aerospace_workspace_change 38 - 39 - for sid in $(aerospace list-workspaces --all); do 40 - sketchybar --add item space.$sid left \ 41 - --subscribe space.$sid aerospace_workspace_change \ 42 - --set space.$sid \ 43 - background.color=0x44ffffff \ 44 - background.corner_radius=5 \ 45 - background.height=20 \ 46 - background.drawing=off \ 47 - label="$sid" \ 48 - click_script="aerospace workspace $sid" 49 - done 50 - 51 - ##### Adding Left Items ##### 52 - # We add some regular items to the left side of the bar, where 53 - # only the properties deviating from the current defaults need to be set 54 - 55 - # sketchybar --add item chevron left \ 56 - # --set chevron icon= label.drawing=off \ 57 - # --add item front_app left \ 58 - # --set front_app icon.drawing=off script="$PLUGIN_DIR/front_app.sh" \ 59 - # --subscribe front_app front_app_switched 60 - 61 - ##### Adding Right Items ##### 62 - # In the same way as the left items we can add items to the right side. 63 - # Additional position (e.g. center) are available, see: 64 - # https://felixkratz.github.io/SketchyBar/config/items#adding-items-to-sketchybar 65 - 66 - # Some items refresh on a fixed cycle, e.g. the clock runs its script once 67 - # every 10s. Other items respond to events they subscribe to, e.g. the 68 - # volume.sh script is only executed once an actual change in system audio 69 - # volume is registered. More info about the event system can be found here: 70 - # https://felixkratz.github.io/SketchyBar/config/events 71 - 72 - # sketchybar --add item clock right \ 73 - # --set clock update_freq=10 icon= script="$PLUGIN_DIR/clock.sh" \ 74 - # --add item volume right \ 75 - # --set volume script="$PLUGIN_DIR/volume.sh" \ 76 - # --subscribe volume volume_change \ 77 - # --add item battery right \ 78 - # --set battery update_freq=120 script="$PLUGIN_DIR/battery.sh" \ 79 - # --subscribe battery system_woke power_source_change 80 - 81 - ##### Force all scripts to run the first time (never do this in a script) ##### 82 - sketchybar --update
+1 -1
home/bates64/gui/default.nix
··· 22 22 ../cli 23 23 ./gl.nix 24 24 ./niri 25 - ./aerospace 25 + ./hammerspoon 26 26 ./ghostty 27 27 ./zed.nix 28 28 ./browser.nix
+35
home/bates64/gui/hammerspoon/default.nix
··· 1 + { 2 + inputs, 3 + config, 4 + lib, 5 + pkgs, 6 + ... 7 + }: 8 + { 9 + imports = [ 10 + inputs.hammerspoon-nix.homeManagerModules.hammerspoon 11 + ]; 12 + 13 + config = lib.mkIf config.isMacOS { 14 + programs.hammerspoon = { 15 + enable = true; 16 + configPath = ./init.lua; 17 + spoons = { 18 + PaperWM = pkgs.fetchFromGitHub { 19 + owner = "mogenson"; 20 + repo = "PaperWM.spoon"; 21 + rev = "41c796a7edd78575aa71b77295672aa0a4a2c3ea"; 22 + sha256 = "0ryck3d6p0rb3zf7wgn83rfn5dqjw98fpbr1cw83jly44sn6d9mv"; 23 + }; 24 + AutoMuteOnSleep = pkgs.fetchzip { 25 + url = "https://github.com/Hammerspoon/Spoons/raw/master/Spoons/AutoMuteOnSleep.spoon.zip"; 26 + sha256 = "13llr8j6iwbd5wvsg9mzmzxz06xsnl6mq83bgbnkyk5jbqhzcvxm"; 27 + }; 28 + MouseFollowsFocus = pkgs.fetchzip { 29 + url = "https://github.com/Hammerspoon/Spoons/raw/master/Spoons/MouseFollowsFocus.spoon.zip"; 30 + sha256 = "0926nv0bix15p5z1sg1jjjbrkcd2xdxzhj6w8xpqh1nvxb3cp3ac"; 31 + }; 32 + }; 33 + }; 34 + }; 35 + }
+91
home/bates64/gui/hammerspoon/init.lua
··· 1 + PaperWM = hs.loadSpoon("PaperWM") 2 + 3 + -- Match niri layout settings 4 + PaperWM.window_gap = 16 5 + PaperWM.window_ratios = { 1 / 3, 1 / 2, 2 / 3 } 6 + 7 + PaperWM.swipe_fingers = 3 8 + PaperWM.lift_window = { "alt", "cmd", "shift" } 9 + 10 + -- Niri-like keybindings 11 + -- Niri uses Mod (Super) as the primary modifier. On macOS, cmd is taken by 12 + -- system shortcuts so we use alt as the equivalent of niri's Mod. 13 + -- 14 + -- Niri PaperWM 15 + -- Mod+H/J/K/L -> alt+H/J/K/L focus 16 + -- Mod+Ctrl+H/J/K/L -> alt+ctrl+H/J/K/L move/swap 17 + -- Mod+R -> alt+R cycle width 18 + -- Mod+Shift+R -> alt+shift+R cycle height 19 + -- Mod+F -> alt+F full width 20 + -- Mod+C -> alt+C center 21 + -- Mod+V -> alt+V toggle floating 22 + -- Mod+[ / Mod+] -> alt+[ / alt+] slurp/barf (consume/expel) 23 + -- Mod+- / Mod+= -> alt+- / alt+= decrease/increase width 24 + -- Mod+1-9 -> alt+1-9 switch space 25 + -- Mod+Ctrl+1-9 -> alt+ctrl+1-9 move window to space 26 + 27 + PaperWM:bindHotkeys({ 28 + -- Focus (niri: Mod+H/J/K/L and Mod+Arrows) 29 + focus_left = { { "alt" }, "h" }, 30 + focus_down = { { "alt" }, "j" }, 31 + focus_up = { { "alt" }, "k" }, 32 + focus_right = { { "alt" }, "l" }, 33 + 34 + -- Swap/move (niri: Mod+Ctrl+H/J/K/L and Mod+Ctrl+Arrows) 35 + swap_left = { { "alt", "ctrl" }, "h" }, 36 + swap_down = { { "alt", "ctrl" }, "j" }, 37 + swap_up = { { "alt", "ctrl" }, "k" }, 38 + swap_right = { { "alt", "ctrl" }, "l" }, 39 + 40 + -- Width cycling (niri: Mod+R / Ctrl+Mod+R) 41 + cycle_width = { { "alt" }, "r" }, 42 + reverse_cycle_width = { { "alt", "ctrl" }, "r" }, 43 + 44 + -- Height cycling (niri: Mod+Shift+R / Ctrl+Mod+Shift+R) 45 + cycle_height = { { "alt", "shift" }, "r" }, 46 + reverse_cycle_height = { { "alt", "ctrl", "shift" }, "r" }, 47 + 48 + -- Width adjustments (niri: Mod+Minus / Mod+Equal) 49 + decrease_width = { { "alt" }, "-" }, 50 + increase_width = { { "alt" }, "=" }, 51 + 52 + -- Full width (niri: Mod+F) 53 + full_width = { { "alt" }, "f" }, 54 + 55 + -- Center (niri: Mod+C) 56 + center_window = { { "alt" }, "c" }, 57 + 58 + -- Toggle floating (niri: Mod+V) 59 + toggle_floating = { { "alt" }, "v" }, 60 + 61 + -- Slurp/barf (niri: Mod+[ consume, Mod+] expel) 62 + slurp_in = { { "alt" }, "[" }, 63 + barf_out = { { "alt" }, "]" }, 64 + 65 + -- Switch space (niri: Mod+1-9) 66 + switch_space_1 = { { "alt" }, "1" }, 67 + switch_space_2 = { { "alt" }, "2" }, 68 + switch_space_3 = { { "alt" }, "3" }, 69 + switch_space_4 = { { "alt" }, "4" }, 70 + switch_space_5 = { { "alt" }, "5" }, 71 + switch_space_6 = { { "alt" }, "6" }, 72 + switch_space_7 = { { "alt" }, "7" }, 73 + switch_space_8 = { { "alt" }, "8" }, 74 + switch_space_9 = { { "alt" }, "9" }, 75 + 76 + -- Move window to space (niri: Mod+Ctrl+1-9) 77 + move_window_1 = { { "alt", "ctrl" }, "1" }, 78 + move_window_2 = { { "alt", "ctrl" }, "2" }, 79 + move_window_3 = { { "alt", "ctrl" }, "3" }, 80 + move_window_4 = { { "alt", "ctrl" }, "4" }, 81 + move_window_5 = { { "alt", "ctrl" }, "5" }, 82 + move_window_6 = { { "alt", "ctrl" }, "6" }, 83 + move_window_7 = { { "alt", "ctrl" }, "7" }, 84 + move_window_8 = { { "alt", "ctrl" }, "8" }, 85 + move_window_9 = { { "alt", "ctrl" }, "9" }, 86 + }) 87 + 88 + PaperWM:start() 89 + 90 + hs.loadSpoon("AutoMuteOnSleep") 91 + hs.loadSpoon("MouseFollowsFocus"):start()
+1 -1
home/bates64/gui/niri/config.kdl
··· 58 58 } 59 59 60 60 // Uncomment this to make the mouse warp to the center of newly focused windows. 61 - //warp-mouse-to-focus 61 + warp-mouse-to-focus 62 62 63 63 // Focus windows and outputs automatically when moving the mouse into them. 64 64 // Setting max-scroll-amount="0%" makes it work only on windows already fully on screen.
+12
hosts/darwin.nix
··· 1 1 { 2 + imports = [ 3 + ../services/darwin/focus-follows-mouse.nix 4 + ]; 5 + 2 6 system.defaults.NSGlobalDomain.AppleFontSmoothing = 0; # https://tonsky.me/blog/monitors/ 3 7 4 8 security.pam.services.sudo_local.touchIdAuth = true; 9 + 10 + homebrew = { 11 + enable = true; 12 + casks = [ 13 + "hammerspoon" 14 + ]; 15 + onActivation.cleanup = "zap"; 16 + }; 5 17 }
+29
services/darwin/focus-follows-mouse.nix
··· 1 + { 2 + config, 3 + lib, 4 + pkgs, 5 + ... 6 + }: 7 + let 8 + autoraise = pkgs.autoraise.overrideAttrs (old: { 9 + buildPhase = '' 10 + runHook preBuild 11 + $CXX -std=c++03 -fobjc-arc -D"NS_FORMAT_ARGUMENT(A)=" -D"SKYLIGHT_AVAILABLE=1" -DEXPERIMENTAL_FOCUS_FIRST -o AutoRaise AutoRaise.mm -framework AppKit -framework SkyLight 12 + bash create-app-bundle.sh 13 + runHook postBuild 14 + ''; 15 + }); 16 + in 17 + { 18 + environment.systemPackages = [ autoraise ]; 19 + 20 + launchd.user.agents.autoraise = { 21 + command = "${autoraise}/bin/autoraise -delay 0 -focusDelay 1"; 22 + serviceConfig = { 23 + KeepAlive = true; 24 + RunAtLoad = true; 25 + StandardOutPath = "/tmp/autoraise.log"; 26 + StandardErrorPath = "/tmp/autoraise.err.log"; 27 + }; 28 + }; 29 + }