diff --git a/common/gui/pipewire.nix b/common/gui/pipewire.nix index 59d66c6..208d301 100644 --- a/common/gui/pipewire.nix +++ b/common/gui/pipewire.nix @@ -6,6 +6,7 @@ }: { # Enable sound with pipewire. hardware.pulseaudio.enable = false; + hardware.alsa.enablePersistence = true; security.rtkit.enable = true; services.pipewire = { enable = true; diff --git a/common/networking/wireless.nix b/common/networking/wireless.nix index 3318f2b..1f8b9cc 100644 --- a/common/networking/wireless.nix +++ b/common/networking/wireless.nix @@ -12,19 +12,19 @@ networking.wireless.enable = true; environment.systemPackages = with pkgs; [wpa_supplicant_gui]; networking.wireless.userControlled.enable = true; - networking.wireless.environmentFile = config.sops.secrets."wireless.env".path; + networking.wireless.secretsFile = config.sops.secrets."wireless.env".path; networking.wireless.networks = { - "@home_uuid@" = { - psk = "@home_psk@"; + "Tycho Station" = { + pskRaw = "ext:home_psk"; priority = 99; }; - "@school_uuid@" = { + "CU-Wireless" = { auth = '' key_mgmt=WPA-EAP eap=PEAP phase2="auth=MSCHAPV2" - identity="@school_identity@" - password="@school_password@" + identity="glengoodwin" + password=ext:school_password ''; priority = 89; }; @@ -34,8 +34,8 @@ key_mgmt=WPA-EAP eap=PEAP phase2="auth=MSCHAPV2" - identity="@eduroam_identity@" - password="@school_password@" + identity="ext:eduroam_identity" + password="ext:school_password" ''; priority = 79; }; diff --git a/common/style/stylix.nix b/common/style/stylix.nix index 2136fdc..e42c04a 100644 --- a/common/style/stylix.nix +++ b/common/style/stylix.nix @@ -1,8 +1,9 @@ {pkgs, ...}: { stylix = { - base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-macchiato.yaml"; + # base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-macchiato.yaml"; + base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-latte.yaml"; # image = ./wallpaper.jpg; - image = ../../wallpapers/nix-black-4k.png; + image = ../../wallpapers/nixos-wallpaper-catppuccin-latte.png; #polarity = "dark"; autoEnable = true; enable = true; diff --git a/flake.lock b/flake.lock index b26e1ae..b8b4208 100644 --- a/flake.lock +++ b/flake.lock @@ -6,11 +6,11 @@ "systems": "systems" }, "locked": { - "lastModified": 1721306136, - "narHash": "sha256-VKPsIGf3/a+RONBipx4lEE4LXG2sdMNkWQu22LNQItg=", + "lastModified": 1727303518, + "narHash": "sha256-lO5JMynTxNZxg/+E4/Y9reeLGIz/M8cEue+Re4cP6qo=", "owner": "Aylur", "repo": "ags", - "rev": "344ea72cd3b8d4911f362fec34bce7d8fb37028c", + "rev": "cd543afec4d9ed708990e5ba52184716809bf248", "type": "github" }, "original": { @@ -39,11 +39,11 @@ ] }, "locked": { - "lastModified": 1723405438, - "narHash": "sha256-bpmC2m7OhlDvqgQZdZ2jBLyeIkq/Jld3X4bqRAxBSp8=", + "lastModified": 1729527199, + "narHash": "sha256-D5/YksfRga8Akd04ZtIkuYSIOjXVrAzQIQBSeplokzU=", "owner": "hyprwm", "repo": "aquamarine", - "rev": "9312aa28271c91e5d67ecb9def527b2bbcff0e66", + "rev": "8d732fa8aff8b12ef2b1e2f00fc8153e41312b72", "type": "github" }, "original": { @@ -86,30 +86,14 @@ "type": "github" } }, - "base16-foot": { - "flake": false, - "locked": { - "lastModified": 1696725948, - "narHash": "sha256-65bz2bUL/yzZ1c8/GQASnoiGwaF8DczlxJtzik1c0AU=", - "owner": "tinted-theming", - "repo": "base16-foot", - "rev": "eedbcfa30de0a4baa03e99f5e3ceb5535c2755ce", - "type": "github" - }, - "original": { - "owner": "tinted-theming", - "repo": "base16-foot", - "type": "github" - } - }, "base16-helix": { "flake": false, "locked": { - "lastModified": 1720809814, - "narHash": "sha256-numb3xigRGnr/deF7wdjBwVg7fpbTH7reFDkJ75AJkY=", + "lastModified": 1725860795, + "narHash": "sha256-Z2o8VBPW3I+KKTSfe25kskz0EUj7MpUh8u355Z1nVsU=", "owner": "tinted-theming", "repo": "base16-helix", - "rev": "34f41987bec14c0f3f6b2155c19787b1f6489625", + "rev": "7f795bf75d38e0eea9fed287264067ca187b88a9", "type": "github" }, "original": { @@ -118,38 +102,6 @@ "type": "github" } }, - "base16-kitty": { - "flake": false, - "locked": { - "lastModified": 1665001328, - "narHash": "sha256-aRaizTYPpuWEcvoYE9U+YRX+Wsc8+iG0guQJbvxEdJY=", - "owner": "kdrag0n", - "repo": "base16-kitty", - "rev": "06bb401fa9a0ffb84365905ffbb959ae5bf40805", - "type": "github" - }, - "original": { - "owner": "kdrag0n", - "repo": "base16-kitty", - "type": "github" - } - }, - "base16-tmux": { - "flake": false, - "locked": { - "lastModified": 1696725902, - "narHash": "sha256-wDPg5elZPcQpu7Df0lI5O8Jv4A3T6jUQIVg63KDU+3Q=", - "owner": "tinted-theming", - "repo": "base16-tmux", - "rev": "c02050bebb60dbb20cb433cd4d8ce668ecc11ba7", - "type": "github" - }, - "original": { - "owner": "tinted-theming", - "repo": "base16-tmux", - "type": "github" - } - }, "base16-vim": { "flake": false, "locked": { @@ -173,11 +125,47 @@ "devenv", "flake-compat" ], + "git-hooks": [ + "devenv", + "pre-commit-hooks" + ], "nixpkgs": [ "devenv", "nixpkgs" + ] + }, + "locked": { + "lastModified": 1726520618, + "narHash": "sha256-jOsaBmJ/EtX5t/vbylCdS7pWYcKGmWOKg4QKUzKr6dA=", + "owner": "cachix", + "repo": "cachix", + "rev": "695525f9086542dfb09fde0871dbf4174abbf634", + "type": "github" + }, + "original": { + "owner": "cachix", + "repo": "cachix", + "type": "github" + } + }, + "cachix_2": { + "inputs": { + "devenv": "devenv_3", + "flake-compat": [ + "devenv", + "cachix", + "devenv", + "flake-compat" + ], + "nixpkgs": [ + "devenv", + "cachix", + "devenv", + "nixpkgs" ], "pre-commit-hooks": [ + "devenv", + "cachix", "devenv", "pre-commit-hooks" ] @@ -200,18 +188,18 @@ "inputs": { "cachix": "cachix", "flake-compat": "flake-compat_2", - "nix": "nix_2", + "nix": "nix_3", "nixpkgs": [ "nixpkgs" ], - "pre-commit-hooks": "pre-commit-hooks" + "pre-commit-hooks": "pre-commit-hooks_2" }, "locked": { - "lastModified": 1723487333, - "narHash": "sha256-jqi/hVQL6S9lj/HkWaPPZQW/BfP0D0Veb45cpSvfRVE=", + "lastModified": 1727779147, + "narHash": "sha256-xMBJNUiSM2cgmr7jd4ziKG5BjELDTKSagVbd6sefIqU=", "owner": "cachix", "repo": "devenv", - "rev": "b285601679c7686f623791ad93a8e0debc322633", + "rev": "eb86c60fc04a8be6a544b2647cc0ca8dc611533e", "type": "github" }, "original": { @@ -223,15 +211,53 @@ }, "devenv_2": { "inputs": { + "cachix": "cachix_2", "flake-compat": [ "devenv", "cachix", "flake-compat" ], + "nix": "nix_2", + "nixpkgs": [ + "devenv", + "cachix", + "nixpkgs" + ], + "pre-commit-hooks": [ + "devenv", + "cachix", + "git-hooks" + ] + }, + "locked": { + "lastModified": 1723156315, + "narHash": "sha256-0JrfahRMJ37Rf1i0iOOn+8Z4CLvbcGNwa2ChOAVrp/8=", + "owner": "cachix", + "repo": "devenv", + "rev": "ff5eb4f2accbcda963af67f1a1159e3f6c7f5f91", + "type": "github" + }, + "original": { + "owner": "cachix", + "repo": "devenv", + "type": "github" + } + }, + "devenv_3": { + "inputs": { + "flake-compat": [ + "devenv", + "cachix", + "devenv", + "cachix", + "flake-compat" + ], "nix": "nix", "nixpkgs": "nixpkgs_2", "poetry2nix": "poetry2nix", "pre-commit-hooks": [ + "devenv", + "cachix", "devenv", "cachix", "pre-commit-hooks" @@ -306,20 +332,6 @@ } }, "flake-compat_3": { - "locked": { - "lastModified": 1696426674, - "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", - "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", - "revCount": 57, - "type": "tarball", - "url": "https://api.flakehub.com/f/pinned/edolstra/flake-compat/1.0.1/018afb31-abd1-7bff-a5e4-cff7e18efb7a/source.tar.gz" - }, - "original": { - "type": "tarball", - "url": "https://flakehub.com/f/edolstra/flake-compat/1.tar.gz" - } - }, - "flake-compat_4": { "flake": false, "locked": { "lastModified": 1696426674, @@ -335,7 +347,37 @@ "type": "github" } }, + "flake-compat_4": { + "locked": { + "lastModified": 1696426674, + "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", + "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", + "revCount": 57, + "type": "tarball", + "url": "https://api.flakehub.com/f/pinned/edolstra/flake-compat/1.0.1/018afb31-abd1-7bff-a5e4-cff7e18efb7a/source.tar.gz" + }, + "original": { + "type": "tarball", + "url": "https://flakehub.com/f/edolstra/flake-compat/1.tar.gz" + } + }, "flake-compat_5": { + "flake": false, + "locked": { + "lastModified": 1696426674, + "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", + "owner": "edolstra", + "repo": "flake-compat", + "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", + "type": "github" + }, + "original": { + "owner": "edolstra", + "repo": "flake-compat", + "type": "github" + } + }, + "flake-compat_6": { "flake": false, "locked": { "lastModified": 1673956053, @@ -351,7 +393,7 @@ "type": "github" } }, - "flake-compat_6": { + "flake-compat_7": { "flake": false, "locked": { "lastModified": 1696426674, @@ -368,6 +410,28 @@ } }, "flake-parts": { + "inputs": { + "nixpkgs-lib": [ + "devenv", + "nix", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1712014858, + "narHash": "sha256-sB4SWl2lX95bExY2gMFG5HIzvva5AVMJd4Igm+GpZNw=", + "owner": "hercules-ci", + "repo": "flake-parts", + "rev": "9126214d0a59633752a136528f5f3b9aa8565b7d", + "type": "github" + }, + "original": { + "owner": "hercules-ci", + "repo": "flake-parts", + "type": "github" + } + }, + "flake-parts_2": { "inputs": { "nixpkgs-lib": [ "nixvim", @@ -375,11 +439,11 @@ ] }, "locked": { - "lastModified": 1722555600, - "narHash": "sha256-XOQkdLafnb/p9ij77byFQjDf5m5QYl9b2REiVClC+x4=", + "lastModified": 1726153070, + "narHash": "sha256-HO4zgY0ekfwO5bX0QH/3kJ/h4KvUDFZg8YpkNwIbg1U=", "owner": "hercules-ci", "repo": "flake-parts", - "rev": "8471fe90ad337a8074e957b69ca4d0089218391d", + "rev": "bcef6817a8b2aa20a5a6dbb19b43e63c5bf8619a", "type": "github" }, "original": { @@ -407,15 +471,12 @@ } }, "flake-utils_2": { - "inputs": { - "systems": "systems_3" - }, "locked": { - "lastModified": 1710146030, - "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", + "lastModified": 1667395993, + "narHash": "sha256-nuEHfE/LcWyuSWnS8t12N1wc105Qtau+/OdUAjtQ0rA=", "owner": "numtide", "repo": "flake-utils", - "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", + "rev": "5aed5285a952e0b949eb3ba02c12fa4fcfef535f", "type": "github" }, "original": { @@ -426,7 +487,28 @@ }, "flake-utils_3": { "inputs": { - "systems": "systems_5" + "systems": "systems_4" + }, + "locked": { + "lastModified": 1726560853, + "narHash": "sha256-X6rJYSESBVr3hBoH0WbKE5KvhPU5bloyZ2L4K60/fPQ=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "c1dfcf08411b08f6b8615f7d8971a2bfa81d5e8a", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, + "flake-utils_4": { + "inputs": { + "systems": [ + "stylix", + "systems" + ] }, "locked": { "lastModified": 1710146030, @@ -442,7 +524,7 @@ "type": "github" } }, - "flake-utils_4": { + "flake-utils_5": { "inputs": { "systems": "systems_6" }, @@ -482,7 +564,7 @@ "nixvim", "flake-compat" ], - "gitignore": "gitignore_2", + "gitignore": "gitignore_3", "nixpkgs": [ "nixvim", "nixpkgs" @@ -493,11 +575,11 @@ ] }, "locked": { - "lastModified": 1723202784, - "narHash": "sha256-qbhjc/NEGaDbyy0ucycubq4N3//gDFFH3DOmp1D3u1Q=", + "lastModified": 1727514110, + "narHash": "sha256-0YRcOxJG12VGDFH8iS8pJ0aYQQUAgo/r3ZAL+cSh9nk=", "owner": "cachix", "repo": "git-hooks.nix", - "rev": "c7012d0c18567c889b948781bc74a501e92275d1", + "rev": "85f7a7177c678de68224af3402ab8ee1bcee25c8", "type": "github" }, "original": { @@ -529,6 +611,28 @@ } }, "gitignore_2": { + "inputs": { + "nixpkgs": [ + "hyprland", + "pre-commit-hooks", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1709087332, + "narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=", + "owner": "hercules-ci", + "repo": "gitignore.nix", + "rev": "637db329424fd7e46cf4185293b9cc8c88c95394", + "type": "github" + }, + "original": { + "owner": "hercules-ci", + "repo": "gitignore.nix", + "type": "github" + } + }, + "gitignore_3": { "inputs": { "nixpkgs": [ "nixvim", @@ -550,7 +654,7 @@ "type": "github" } }, - "gitignore_3": { + "gitignore_4": { "inputs": { "nixpkgs": [ "pre-commit-hooks", @@ -620,11 +724,11 @@ ] }, "locked": { - "lastModified": 1723399884, - "narHash": "sha256-97wn0ihhGqfMb8WcUgzzkM/TuAxce2Gd20A8oiruju4=", + "lastModified": 1727383923, + "narHash": "sha256-4/vacp3CwdGoPf8U4e/N8OsGYtO09WTcQK5FqYfJbKs=", "owner": "nix-community", "repo": "home-manager", - "rev": "086f619dd991a4d355c07837448244029fc2d9ab", + "rev": "ffe2d07e771580a005e675108212597e5b367d2d", "type": "github" }, "original": { @@ -642,11 +746,11 @@ ] }, "locked": { - "lastModified": 1723399884, - "narHash": "sha256-97wn0ihhGqfMb8WcUgzzkM/TuAxce2Gd20A8oiruju4=", + "lastModified": 1727383923, + "narHash": "sha256-4/vacp3CwdGoPf8U4e/N8OsGYtO09WTcQK5FqYfJbKs=", "owner": "nix-community", "repo": "home-manager", - "rev": "086f619dd991a4d355c07837448244029fc2d9ab", + "rev": "ffe2d07e771580a005e675108212597e5b367d2d", "type": "github" }, "original": { @@ -663,11 +767,11 @@ ] }, "locked": { - "lastModified": 1715930644, - "narHash": "sha256-W9pyM3/vePxrffHtzlJI6lDS3seANQ+Nqp+i58O46LI=", + "lastModified": 1724435763, + "narHash": "sha256-UNky3lJNGQtUEXT2OY8gMxejakSWPTfWKvpFkpFlAfM=", "owner": "nix-community", "repo": "home-manager", - "rev": "e3ad5108f54177e6520535768ddbf1e6af54b59d", + "rev": "c2cd2a52e02f1dfa1c88f95abeb89298d46023be", "type": "github" }, "original": { @@ -692,11 +796,11 @@ ] }, "locked": { - "lastModified": 1722623071, - "narHash": "sha256-sLADpVgebpCBFXkA1FlCXtvEPu1tdEsTfqK1hfeHySE=", + "lastModified": 1728669738, + "narHash": "sha256-EDNAU9AYcx8OupUzbTbWE1d3HYdeG0wO6Msg3iL1muk=", "owner": "hyprwm", "repo": "hyprcursor", - "rev": "912d56025f03d41b1ad29510c423757b4379eb1c", + "rev": "0264e698149fcb857a66a53018157b41f8d97bb0", "type": "github" }, "original": { @@ -709,19 +813,21 @@ "inputs": { "aquamarine": "aquamarine", "hyprcursor": "hyprcursor", + "hyprland-protocols": "hyprland-protocols", "hyprlang": "hyprlang", "hyprutils": "hyprutils", "hyprwayland-scanner": "hyprwayland-scanner", - "nixpkgs": "nixpkgs_3", - "systems": "systems_4", + "nixpkgs": "nixpkgs_4", + "pre-commit-hooks": "pre-commit-hooks_3", + "systems": "systems_3", "xdph": "xdph" }, "locked": { - "lastModified": 1723656907, - "narHash": "sha256-11tgstIQZP3RRrBEF3ym9L6oS+vzqZJ7Mp6eB2PaN+0=", + "lastModified": 1730122745, + "narHash": "sha256-K9qqg8MgKzbgAUWCryplQ36hly8AGfkMloeVOZ/tPiY=", "ref": "refs/heads/main", - "rev": "197f8807900afc81c1c92ad17e621d1998ee268b", - "revCount": 5088, + "rev": "2c481202effe707451608e272b5a801f8c970052", + "revCount": 5386, "submodules": true, "type": "git", "url": "https://github.com/hyprwm/Hyprland" @@ -736,21 +842,19 @@ "inputs": { "nixpkgs": [ "hyprland", - "xdph", "nixpkgs" ], "systems": [ "hyprland", - "xdph", "systems" ] }, "locked": { - "lastModified": 1721326555, - "narHash": "sha256-zCu4R0CSHEactW9JqYki26gy8h9f6rHmSwj4XJmlHgg=", + "lastModified": 1728345020, + "narHash": "sha256-xGbkc7U/Roe0/Cv3iKlzijIaFBNguasI31ynL2IlEoM=", "owner": "hyprwm", "repo": "hyprland-protocols", - "rev": "5a11232266bf1a1f5952d5b179c3f4b2facaaa84", + "rev": "a7c183800e74f337753de186522b9017a07a8cee", "type": "github" }, "original": { @@ -775,11 +879,11 @@ ] }, "locked": { - "lastModified": 1721324361, - "narHash": "sha256-BiJKO0IIdnSwHQBSrEJlKlFr753urkLE48wtt0UhNG4=", + "lastModified": 1728168612, + "narHash": "sha256-AnB1KfiXINmuiW7BALYrKqcjCnsLZPifhb/7BsfPbns=", "owner": "hyprwm", "repo": "hyprlang", - "rev": "adbefbf49664a6c2c8bf36b6487fd31e3eb68086", + "rev": "f054f2e44d6a0b74607a6bc0f52dba337a3db38e", "type": "github" }, "original": { @@ -800,11 +904,11 @@ ] }, "locked": { - "lastModified": 1722869141, - "narHash": "sha256-0KU4qhyMp441qfwbirNg3+wbm489KnEjXOz2I/RbeFs=", + "lastModified": 1728941256, + "narHash": "sha256-WRypmcZ2Bw94lLmcmxYokVOHPJSZ7T06V49QZ4tkZeQ=", "owner": "hyprwm", "repo": "hyprutils", - "rev": "0252fd13e78e60fb0da512a212e56007515a49f7", + "rev": "fd4be8b9ca932f7384e454bcd923c5451ef2aa85", "type": "github" }, "original": { @@ -825,11 +929,11 @@ ] }, "locked": { - "lastModified": 1721324119, - "narHash": "sha256-SOOqIT27/X792+vsLSeFdrNTF+OSRp5qXv6Te+fb2Qg=", + "lastModified": 1726874836, + "narHash": "sha256-VKR0sf0PSNCB0wPHVKSAn41mCNVCnegWmgkrneKDhHM=", "owner": "hyprwm", "repo": "hyprwayland-scanner", - "rev": "a048a6cb015340bd82f97c1f40a4b595ca85cc30", + "rev": "500c81a9e1a76760371049a8d99e008ea77aa59e", "type": "github" }, "original": { @@ -838,10 +942,28 @@ "type": "github" } }, + "libgit2": { + "flake": false, + "locked": { + "lastModified": 1697646580, + "narHash": "sha256-oX4Z3S9WtJlwvj0uH9HlYcWv+x1hqp8mhXl7HsLu2f0=", + "owner": "libgit2", + "repo": "libgit2", + "rev": "45fd9ed7ae1a9b74b957ef4f337bc3c8b3df01b5", + "type": "github" + }, + "original": { + "owner": "libgit2", + "repo": "libgit2", + "type": "github" + } + }, "nix": { "inputs": { "flake-compat": "flake-compat", "nixpkgs": [ + "devenv", + "cachix", "devenv", "cachix", "devenv", @@ -872,11 +994,11 @@ ] }, "locked": { - "lastModified": 1722924007, - "narHash": "sha256-+CQDamNwqO33REJLft8c26NbUi2Td083hq6SvAm2xkU=", + "lastModified": 1727507295, + "narHash": "sha256-I/FrX1peu4URoj5T5odfuKR2rm4GjYJJpCGF9c0/lDA=", "owner": "lnl7", "repo": "nix-darwin", - "rev": "91010a5613ffd7ee23ee9263213157a1c422b705", + "rev": "f2e1c4aa29fc211947c3a7113cba1dd707433b70", "type": "github" }, "original": { @@ -888,6 +1010,8 @@ "nix-github-actions": { "inputs": { "nixpkgs": [ + "devenv", + "cachix", "devenv", "cachix", "devenv", @@ -916,11 +1040,11 @@ ] }, "locked": { - "lastModified": 1723352546, - "narHash": "sha256-WTIrvp0yV8ODd6lxAq4F7EbrPQv0gscBnyfn559c3k8=", + "lastModified": 1727658919, + "narHash": "sha256-YAePt2GldkkRJ08LvZNHcuS6shIVStj+K+1DZN3gbnM=", "owner": "Mic92", "repo": "nix-index-database", - "rev": "ec78079a904d7d55e81a0468d764d0fffb50ac06", + "rev": "f9fdf8285690a351e8998f1e703ebdf9cdf51dee", "type": "github" }, "original": { @@ -932,10 +1056,14 @@ "nix_2": { "inputs": { "flake-compat": [ + "devenv", + "cachix", "devenv", "flake-compat" ], "nixpkgs": [ + "devenv", + "cachix", "devenv", "nixpkgs" ], @@ -956,13 +1084,41 @@ "type": "github" } }, + "nix_3": { + "inputs": { + "flake-compat": [ + "devenv", + "flake-compat" + ], + "flake-parts": "flake-parts", + "libgit2": "libgit2", + "nixpkgs": "nixpkgs_3", + "nixpkgs-23-11": "nixpkgs-23-11", + "nixpkgs-regression": "nixpkgs-regression_3", + "pre-commit-hooks": "pre-commit-hooks" + }, + "locked": { + "lastModified": 1727438425, + "narHash": "sha256-X8ES7I1cfNhR9oKp06F6ir4Np70WGZU5sfCOuNBEwMg=", + "owner": "domenkozar", + "repo": "nix", + "rev": "f6c5ae4c1b2e411e6b1e6a8181cc84363d6a7546", + "type": "github" + }, + "original": { + "owner": "domenkozar", + "ref": "devenv-2.24", + "repo": "nix", + "type": "github" + } + }, "nixpkgs": { "locked": { - "lastModified": 1718714799, - "narHash": "sha256-FUZpz9rg3gL8NVPKbqU8ei1VkPLsTIfAJ2fdAf5qjak=", + "lastModified": 1725634671, + "narHash": "sha256-v3rIhsJBOMLR8e/RNWxr828tB+WywYIoajrZKFM+0Gg=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c00d587b1a1afbf200b1d8f0b0e4ba9deb1c7f0e", + "rev": "574d1eac1c200690e27b8eb4e24887f8df7ac27c", "type": "github" }, "original": { @@ -972,6 +1128,22 @@ "type": "github" } }, + "nixpkgs-23-11": { + "locked": { + "lastModified": 1717159533, + "narHash": "sha256-oamiKNfr2MS6yH64rUn99mIZjc45nGJlj9eGth/3Xuw=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "a62e6edd6d5e1fa0329b8653c801147986f8d446", + "type": "github" + }, + "original": { + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "a62e6edd6d5e1fa0329b8653c801147986f8d446", + "type": "github" + } + }, "nixpkgs-regression": { "locked": { "lastModified": 1643052045, @@ -1004,18 +1176,34 @@ "type": "github" } }, - "nixpkgs-stable": { + "nixpkgs-regression_3": { "locked": { - "lastModified": 1710695816, - "narHash": "sha256-3Eh7fhEID17pv9ZxrPwCLfqXnYP006RKzSs0JptsN84=", + "lastModified": 1643052045, + "narHash": "sha256-uGJ0VXIhWKGXxkeNnq4TvV3CIOkUJ3PAoLZ3HMzNVMw=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "614b4613980a522ba49f0d194531beddbb7220d3", + "rev": "215d4d0fd80ca5163643b03a33fde804a29cc1e2", "type": "github" }, "original": { "owner": "NixOS", - "ref": "nixos-23.11", + "repo": "nixpkgs", + "rev": "215d4d0fd80ca5163643b03a33fde804a29cc1e2", + "type": "github" + } + }, + "nixpkgs-stable": { + "locked": { + "lastModified": 1720386169, + "narHash": "sha256-NGKVY4PjzwAa4upkGtAMz1npHGoRzWotlSnVlqI40mo=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "194846768975b7ad2c4988bdb82572c00222c0d7", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-24.05", "repo": "nixpkgs", "type": "github" } @@ -1038,11 +1226,27 @@ }, "nixpkgs-stable_3": { "locked": { - "lastModified": 1721524707, - "narHash": "sha256-5NctRsoE54N86nWd0psae70YSLfrOek3Kv1e8KoXe/0=", + "lastModified": 1720386169, + "narHash": "sha256-NGKVY4PjzwAa4upkGtAMz1npHGoRzWotlSnVlqI40mo=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "556533a23879fc7e5f98dd2e0b31a6911a213171", + "rev": "194846768975b7ad2c4988bdb82572c00222c0d7", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-24.05", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs-stable_4": { + "locked": { + "lastModified": 1725762081, + "narHash": "sha256-vNv+aJUW5/YurRy1ocfvs4q/48yVESwlC/yHzjkZSP8=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "dc454045f5b5d814e5862a6d057e7bb5c29edc05", "type": "github" }, "original": { @@ -1054,11 +1258,11 @@ }, "nixpkgs-unstable": { "locked": { - "lastModified": 1723362943, - "narHash": "sha256-dFZRVSgmJkyM0bkPpaYRtG/kRMRTorUIDj8BxoOt1T4=", + "lastModified": 1727634051, + "narHash": "sha256-S5kVU7U82LfpEukbn/ihcyNt2+EvG7Z5unsKW9H/yFA=", "owner": "nixos", "repo": "nixpkgs", - "rev": "a58bc8ad779655e790115244571758e8de055e3d", + "rev": "06cf0e1da4208d3766d898b7fdab6513366d45b9", "type": "github" }, "original": { @@ -1086,31 +1290,31 @@ }, "nixpkgs_3": { "locked": { - "lastModified": 1723175592, - "narHash": "sha256-M0xJ3FbDUc4fRZ84dPGx5VvgFsOzds77KiBMW/mMTnI=", + "lastModified": 1717432640, + "narHash": "sha256-+f9c4/ZX5MWDOuB1rKoWj+lBNm0z0rs4CK47HBLxy1o=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "5e0ca22929f3342b19569b21b2f3462f053e497b", + "rev": "88269ab3044128b7c2f4c7d68448b2fb50456870", "type": "github" }, "original": { "owner": "NixOS", - "ref": "nixos-unstable", + "ref": "release-24.05", "repo": "nixpkgs", "type": "github" } }, "nixpkgs_4": { "locked": { - "lastModified": 1723362943, - "narHash": "sha256-dFZRVSgmJkyM0bkPpaYRtG/kRMRTorUIDj8BxoOt1T4=", - "owner": "nixos", + "lastModified": 1729413321, + "narHash": "sha256-I4tuhRpZFa6Fu6dcH9Dlo5LlH17peT79vx1y1SpeKt0=", + "owner": "NixOS", "repo": "nixpkgs", - "rev": "a58bc8ad779655e790115244571758e8de055e3d", + "rev": "1997e4aa514312c1af7e2bda7fad1644e778ff26", "type": "github" }, "original": { - "owner": "nixos", + "owner": "NixOS", "ref": "nixos-unstable", "repo": "nixpkgs", "type": "github" @@ -1118,11 +1322,27 @@ }, "nixpkgs_5": { "locked": { - "lastModified": 1723175592, - "narHash": "sha256-M0xJ3FbDUc4fRZ84dPGx5VvgFsOzds77KiBMW/mMTnI=", + "lastModified": 1727634051, + "narHash": "sha256-S5kVU7U82LfpEukbn/ihcyNt2+EvG7Z5unsKW9H/yFA=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "06cf0e1da4208d3766d898b7fdab6513366d45b9", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_6": { + "locked": { + "lastModified": 1727348695, + "narHash": "sha256-J+PeFKSDV+pHL7ukkfpVzCOO7mBSrrpJ3svwBFABbhI=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "5e0ca22929f3342b19569b21b2f3462f053e497b", + "rev": "1925c603f17fc89f4c8f6bf6f631a802ad85d784", "type": "github" }, "original": { @@ -1132,13 +1352,13 @@ "type": "github" } }, - "nixpkgs_6": { + "nixpkgs_7": { "locked": { - "lastModified": 1721466660, - "narHash": "sha256-pFSxgSZqZ3h+5Du0KvEL1ccDZBwu4zvOil1zzrPNb3c=", + "lastModified": 1725534445, + "narHash": "sha256-Yd0FK9SkWy+ZPuNqUgmVPXokxDgMJoGuNpMEtkfcf84=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "6e14bbce7bea6c4efd7adfa88a40dac750d80100", + "rev": "9bb1e7571aadf31ddb4af77fc64b2d59580f9a39", "type": "github" }, "original": { @@ -1148,7 +1368,7 @@ "type": "github" } }, - "nixpkgs_7": { + "nixpkgs_8": { "locked": { "lastModified": 1715534503, "narHash": "sha256-5ZSVkFadZbFP1THataCaSf0JH2cAH3S29hU9rrxTEqk=", @@ -1167,21 +1387,21 @@ "nixvim": { "inputs": { "devshell": "devshell", - "flake-compat": "flake-compat_3", - "flake-parts": "flake-parts", + "flake-compat": "flake-compat_4", + "flake-parts": "flake-parts_2", "git-hooks": "git-hooks", "home-manager": "home-manager_2", "nix-darwin": "nix-darwin", - "nixpkgs": "nixpkgs_5", + "nixpkgs": "nixpkgs_6", "nuschtosSearch": "nuschtosSearch", "treefmt-nix": "treefmt-nix" }, "locked": { - "lastModified": 1723670331, - "narHash": "sha256-bQaWqflbYdOn28NJHMTMMPgswlQRXhZh+a3WQAeyaFE=", + "lastModified": 1727645871, + "narHash": "sha256-Os3PAThU5XliKkKa+SHsFyV/EsCHogHcYONmpzb6500=", "owner": "nix-community", "repo": "nixvim", - "rev": "a96aa9730af8c85dd7ed15e359ac23e9686f0a9a", + "rev": "5f4a4b47597d3b9ac26c41ff4e8da28fa662f200", "type": "github" }, "original": { @@ -1199,11 +1419,11 @@ ] }, "locked": { - "lastModified": 1723367906, - "narHash": "sha256-v1qA4WBGDI2uH/TVqRwuXSBP341W681psbzYJ8zrjog=", + "lastModified": 1727452028, + "narHash": "sha256-ehl/A4HQFRyqj1Fk7cl+dgSf/2Fb1jLwWJtZaMU6RfU=", "owner": "NuschtOS", "repo": "search", - "rev": "6ca2c3ae05a915c160512bd41f6810f456c9b30d", + "rev": "9f7426e532ef8dfc839c4a3fcc567b13a20a70d3", "type": "github" }, "original": { @@ -1217,6 +1437,8 @@ "flake-utils": "flake-utils", "nix-github-actions": "nix-github-actions", "nixpkgs": [ + "devenv", + "cachix", "devenv", "cachix", "devenv", @@ -1241,22 +1463,30 @@ "inputs": { "flake-compat": [ "devenv", - "flake-compat" + "nix" ], "flake-utils": "flake-utils_2", - "gitignore": "gitignore", + "gitignore": [ + "devenv", + "nix" + ], "nixpkgs": [ "devenv", + "nix", "nixpkgs" ], - "nixpkgs-stable": "nixpkgs-stable" + "nixpkgs-stable": [ + "devenv", + "nix", + "nixpkgs" + ] }, "locked": { - "lastModified": 1713775815, - "narHash": "sha256-Wu9cdYTnGQQwtT20QQMg7jzkANKQjwBD9iccfGKkfls=", + "lastModified": 1712897695, + "narHash": "sha256-nMirxrGteNAl9sWiOhoN5tIHyjBbVi5e2tgZUgZlK3Y=", "owner": "cachix", "repo": "pre-commit-hooks.nix", - "rev": "2ac4dcbf55ed43f3be0bae15e181f08a57af24a4", + "rev": "40e6053ecb65fcbf12863338a6dcefb3f55f1bf8", "type": "github" }, "original": { @@ -1267,19 +1497,70 @@ }, "pre-commit-hooks_2": { "inputs": { - "flake-compat": "flake-compat_4", - "gitignore": "gitignore_3", + "flake-compat": [ + "devenv", + "flake-compat" + ], + "gitignore": "gitignore", "nixpkgs": [ + "devenv", + "nixpkgs" + ], + "nixpkgs-stable": "nixpkgs-stable" + }, + "locked": { + "lastModified": 1726745158, + "narHash": "sha256-D5AegvGoEjt4rkKedmxlSEmC+nNLMBPWFxvmYnVLhjk=", + "owner": "cachix", + "repo": "pre-commit-hooks.nix", + "rev": "4e743a6920eab45e8ba0fbe49dc459f1423a4b74", + "type": "github" + }, + "original": { + "owner": "cachix", + "repo": "pre-commit-hooks.nix", + "type": "github" + } + }, + "pre-commit-hooks_3": { + "inputs": { + "flake-compat": "flake-compat_3", + "gitignore": "gitignore_2", + "nixpkgs": [ + "hyprland", "nixpkgs" ], "nixpkgs-stable": "nixpkgs-stable_2" }, "locked": { - "lastModified": 1723202784, - "narHash": "sha256-qbhjc/NEGaDbyy0ucycubq4N3//gDFFH3DOmp1D3u1Q=", + "lastModified": 1729104314, + "narHash": "sha256-pZRZsq5oCdJt3upZIU4aslS9XwFJ+/nVtALHIciX/BI=", + "owner": "cachix", + "repo": "git-hooks.nix", + "rev": "3c3e88f0f544d6bb54329832616af7eb971b6be6", + "type": "github" + }, + "original": { + "owner": "cachix", + "repo": "git-hooks.nix", + "type": "github" + } + }, + "pre-commit-hooks_4": { + "inputs": { + "flake-compat": "flake-compat_5", + "gitignore": "gitignore_4", + "nixpkgs": [ + "nixpkgs" + ], + "nixpkgs-stable": "nixpkgs-stable_3" + }, + "locked": { + "lastModified": 1727514110, + "narHash": "sha256-0YRcOxJG12VGDFH8iS8pJ0aYQQUAgo/r3ZAL+cSh9nk=", "owner": "cachix", "repo": "pre-commit-hooks.nix", - "rev": "c7012d0c18567c889b948781bc74a501e92275d1", + "rev": "85f7a7177c678de68224af3402ab8ee1bcee25c8", "type": "github" }, "original": { @@ -1295,10 +1576,10 @@ "home-manager": "home-manager", "hyprland": "hyprland", "nix-index-database": "nix-index-database", - "nixpkgs": "nixpkgs_4", + "nixpkgs": "nixpkgs_5", "nixpkgs-unstable": "nixpkgs-unstable", "nixvim": "nixvim", - "pre-commit-hooks": "pre-commit-hooks_2", + "pre-commit-hooks": "pre-commit-hooks_4", "sops-nix": "sops-nix", "stylix": "stylix", "superfile": "superfile" @@ -1306,15 +1587,15 @@ }, "sops-nix": { "inputs": { - "nixpkgs": "nixpkgs_6", - "nixpkgs-stable": "nixpkgs-stable_3" + "nixpkgs": "nixpkgs_7", + "nixpkgs-stable": "nixpkgs-stable_4" }, "locked": { - "lastModified": 1723501126, - "narHash": "sha256-N9IcHgj/p1+2Pvk8P4Zc1bfrMwld5PcosVA0nL6IGdE=", + "lastModified": 1727734513, + "narHash": "sha256-i47LQwoGCVQq4upV2YHV0OudkauHNuFsv306ualB/Sw=", "owner": "Mic92", "repo": "sops-nix", - "rev": "be0eec2d27563590194a9206f551a6f73d52fa34", + "rev": "3198a242e547939c5e659353551b0668ec150268", "type": "github" }, "original": { @@ -1327,24 +1608,26 @@ "inputs": { "base16": "base16", "base16-fish": "base16-fish", - "base16-foot": "base16-foot", "base16-helix": "base16-helix", - "base16-kitty": "base16-kitty", - "base16-tmux": "base16-tmux", "base16-vim": "base16-vim", - "flake-compat": "flake-compat_5", + "flake-compat": "flake-compat_6", + "flake-utils": "flake-utils_4", "gnome-shell": "gnome-shell", "home-manager": "home-manager_3", "nixpkgs": [ "nixpkgs" - ] + ], + "systems": "systems_5", + "tinted-foot": "tinted-foot", + "tinted-kitty": "tinted-kitty", + "tinted-tmux": "tinted-tmux" }, "locked": { - "lastModified": 1722946882, - "narHash": "sha256-mxtnMye8gs82tdQbVC+g6v3aPOZlH150f9WyntHIkTg=", + "lastModified": 1727723275, + "narHash": "sha256-k4HrG8TJQ0RqDS1tlDz71kvWFBNQ7qZI9T5Z0qLR85Y=", "owner": "danth", "repo": "stylix", - "rev": "5853f1a8bd072f2ebabfc3de3973084353cf6f1e", + "rev": "e7e97059776da7e34b739415a7bc8f80f606b803", "type": "github" }, "original": { @@ -1355,17 +1638,17 @@ }, "superfile": { "inputs": { - "flake-compat": "flake-compat_6", - "flake-utils": "flake-utils_4", + "flake-compat": "flake-compat_7", + "flake-utils": "flake-utils_5", "gomod2nix": "gomod2nix", - "nixpkgs": "nixpkgs_7" + "nixpkgs": "nixpkgs_8" }, "locked": { - "lastModified": 1722991483, - "narHash": "sha256-pGc6ufZO12n99ZXkYIlmdb7JkP2NSa9SfEAHyIUB0rc=", + "lastModified": 1727265805, + "narHash": "sha256-HCNzWjK0J5n9INnWWcFvDOSV3k2TlZDHyvrI+sxjxpo=", "owner": "MHNightCat", "repo": "superfile", - "rev": "2a84d04edc97af5a2134395cb5ed2a084249d6e7", + "rev": "e0ca5d84b2359a8fc1c89c04b4d82aea040d7ea1", "type": "github" }, "original": { @@ -1405,21 +1688,6 @@ } }, "systems_3": { - "locked": { - "lastModified": 1681028828, - "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", - "owner": "nix-systems", - "repo": "default", - "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default", - "type": "github" - } - }, - "systems_4": { "locked": { "lastModified": 1689347949, "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", @@ -1434,6 +1702,21 @@ "type": "github" } }, + "systems_4": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + }, "systems_5": { "locked": { "lastModified": 1681028828, @@ -1464,6 +1747,54 @@ "type": "github" } }, + "tinted-foot": { + "flake": false, + "locked": { + "lastModified": 1696725948, + "narHash": "sha256-65bz2bUL/yzZ1c8/GQASnoiGwaF8DczlxJtzik1c0AU=", + "owner": "tinted-theming", + "repo": "tinted-foot", + "rev": "eedbcfa30de0a4baa03e99f5e3ceb5535c2755ce", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "tinted-foot", + "type": "github" + } + }, + "tinted-kitty": { + "flake": false, + "locked": { + "lastModified": 1665001328, + "narHash": "sha256-aRaizTYPpuWEcvoYE9U+YRX+Wsc8+iG0guQJbvxEdJY=", + "owner": "tinted-theming", + "repo": "tinted-kitty", + "rev": "06bb401fa9a0ffb84365905ffbb959ae5bf40805", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "tinted-kitty", + "type": "github" + } + }, + "tinted-tmux": { + "flake": false, + "locked": { + "lastModified": 1696725902, + "narHash": "sha256-wDPg5elZPcQpu7Df0lI5O8Jv4A3T6jUQIVg63KDU+3Q=", + "owner": "tinted-theming", + "repo": "tinted-tmux", + "rev": "c02050bebb60dbb20cb433cd4d8ce668ecc11ba7", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "tinted-tmux", + "type": "github" + } + }, "treefmt-nix": { "inputs": { "nixpkgs": [ @@ -1472,11 +1803,11 @@ ] }, "locked": { - "lastModified": 1723454642, - "narHash": "sha256-S0Gvsenh0II7EAaoc9158ZB4vYyuycvMGKGxIbERNAM=", + "lastModified": 1727431250, + "narHash": "sha256-uGRlRT47ecicF9iLD1G3g43jn2e+b5KaMptb59LHnvM=", "owner": "numtide", "repo": "treefmt-nix", - "rev": "349de7bc435bdff37785c2466f054ed1766173be", + "rev": "879b29ae9a0378904fbbefe0dadaed43c8905754", "type": "github" }, "original": { @@ -1487,11 +1818,22 @@ }, "xdph": { "inputs": { - "hyprland-protocols": "hyprland-protocols", + "hyprland-protocols": [ + "hyprland", + "hyprland-protocols" + ], "hyprlang": [ "hyprland", "hyprlang" ], + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "hyprwayland-scanner": [ + "hyprland", + "hyprwayland-scanner" + ], "nixpkgs": [ "hyprland", "nixpkgs" @@ -1502,11 +1844,11 @@ ] }, "locked": { - "lastModified": 1722365976, - "narHash": "sha256-Khdm+mDzYA//XaU0M+hftod+rKr5q9SSHSEuiQ0/9ow=", + "lastModified": 1728166987, + "narHash": "sha256-w6dVTguAn9zJ+7aPOhBQgDz8bn6YZ7b56cY8Kg5HJRI=", "owner": "hyprwm", "repo": "xdg-desktop-portal-hyprland", - "rev": "7f2a77ddf60390248e2a3de2261d7102a13e5341", + "rev": "fb9c8d665af0588bb087f97d0f673ddf0d501787", "type": "github" }, "original": { diff --git a/home-manager/machines/candlekeep.nix b/home-manager/machines/candlekeep.nix index 48c0a61..58e27ec 100644 --- a/home-manager/machines/candlekeep.nix +++ b/home-manager/machines/candlekeep.nix @@ -65,8 +65,8 @@ }; stylix = { - base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-macchiato.yaml"; - image = ../../wallpapers/nix-black-4k.png; + base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-latte.yaml"; + image = ../../wallpapers/nixos-wallpaper-catppuccin-latte.png; autoEnable = true; enable = true; diff --git a/home-manager/machines/grymforge.nix b/home-manager/machines/grymforge.nix index 258144a..af104e5 100644 --- a/home-manager/machines/grymforge.nix +++ b/home-manager/machines/grymforge.nix @@ -65,8 +65,9 @@ }; stylix = { - base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-macchiato.yaml"; - image = ../../wallpapers/nix-black-4k.png; + # base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-macchiato.yaml"; + base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-latte.yaml"; + image = ../../wallpapers/nixos-wallpaper-catppuccin-latte.png; # polarity = "dark"; autoEnable = true; enable = true; diff --git a/home-manager/modules/linux-gui.nix b/home-manager/modules/linux-gui.nix index a4ce10e..fe575aa 100644 --- a/home-manager/modules/linux-gui.nix +++ b/home-manager/modules/linux-gui.nix @@ -20,9 +20,12 @@ #sublime-music # A modern and feature-rich music player with a clean user interface and advanced playback options. thunderbird # Mozilla Thunderbird, a powerful and customizable email client with integrated calendaring and chat features. wireshark # Open-source network protocol analyzer for real-time packet inspection and analysis. + inkscape nicotine-plus anki obsidian + chromium vlc + zotero ]; } diff --git a/home-manager/modules/neovim/autocommands.nix b/home-manager/modules/neovim/autocommands.nix index 562efae..4feba30 100644 --- a/home-manager/modules/neovim/autocommands.nix +++ b/home-manager/modules/neovim/autocommands.nix @@ -16,6 +16,16 @@ ]; command = "setlocal spell spelllang=en_us"; } + + { + event = "FileType"; + pattern = [ + "tex" + "latex" + "markdown" + ]; + command = "setlocal wrap"; + } ]; }; } diff --git a/home-manager/modules/neovim/plugins/bufferline.nix b/home-manager/modules/neovim/plugins/bufferline.nix index 4e628d6..9a326db 100644 --- a/home-manager/modules/neovim/plugins/bufferline.nix +++ b/home-manager/modules/neovim/plugins/bufferline.nix @@ -3,10 +3,10 @@ plugins.bufferline = let mouse = { right = - # lua + # Lua "'vertical sbuffer %d'"; close = - # lua + # Lua '' function(bufnum) require("mini.bufremove").delete(bufnum) @@ -25,7 +25,7 @@ close_icon = ""; diagnostics = "nvim_lsp"; diagnostics_indicator = - # lua + # Lua '' function(count, level, diagnostics_dict, context) local s = "" @@ -57,13 +57,11 @@ }; priority = 2; # icon = ""; - matcher.__raw = - # lua - '' - function(buf) - return buf.name:match('%test') or buf.name:match('%.spec') - end - ''; + matcher.__raw = '' + function(buf) + return buf.name:match('%test') or buf.name:match('%.spec') + end + ''; } { name = "Docs"; @@ -73,13 +71,11 @@ sp = "#494d64"; }; auto_close = false; - matcher.__raw = - # lua - '' - function(buf) - return buf.name:match('%.md') or buf.name:match('%.txt') - end - ''; + matcher.__raw = '' + function(buf) + return buf.name:match('%.md') or buf.name:match('%.txt') + end + ''; } ]; }; @@ -94,13 +90,11 @@ max_prefix_length = 15; modified_icon = "●"; - numbers.__raw = - # lua - '' - function(opts) - return string.format('%s·%s', opts.raise(opts.id), opts.lower(opts.ordinal)) - end - ''; + numbers.__raw = '' + function(opts) + return string.format('%s·%s', opts.raise(opts.id), opts.lower(opts.ordinal)) + end + ''; persist_buffer_sort = true; right_mouse_command.__raw = mouse.right; @@ -122,61 +116,6 @@ } ]; }; - - # NOTE: fixes colorscheme with transparent_background - # and better contrast selected tabs - highlights = let - commonBgColor = "#363a4f"; - commonFgColor = "#1e2030"; - - commonSelectedAttrs = { - bg = commonBgColor; - }; - - # Define a set with common selected attributes - selectedAttrsSet = builtins.listToAttrs ( - map - (name: { - inherit name; - value = commonSelectedAttrs; - }) - [ - # "separator_selected" # Handled uniquely - "buffer_selected" - "tab_selected" - "numbers_selected" - "close_button_selected" - "duplicate_selected" - "modified_selected" - "info_selected" - "warning_selected" - "error_selected" - "hint_selected" - "diagnostic_selected" - "info_diagnostic_selected" - "warning_diagnostic_selected" - "error_diagnostic_selected" - "hint_diagnostic_selected" - ] - ); - in - # Merge the common selected attributes with the unique attributes - selectedAttrsSet - // { - fill = { - bg = commonFgColor; - }; - separator = { - fg = commonFgColor; - }; - separator_visible = { - fg = commonFgColor; - }; - separator_selected = { - bg = commonBgColor; - fg = commonFgColor; - }; - }; }; }; @@ -184,46 +123,41 @@ { mode = "n"; key = "bP"; - action = ":BufferLineTogglePin"; + action = "BufferLineTogglePin"; options = { desc = "Pin buffer toggle"; - silent = true; }; } { mode = "n"; key = "bp"; - action = ":BufferLinePick"; + action = "BufferLinePick"; options = { desc = "Pick Buffer"; - silent = true; }; } { mode = "n"; key = "bsd"; - action = ":BufferLineSortByDirectory"; + action = "BufferLineSortByDirectory"; options = { desc = "Sort By Directory"; - silent = true; }; } { mode = "n"; key = "bse"; - action = ":BufferLineSortByExtension"; + action = "BufferLineSortByExtension"; options = { desc = "Sort By Extension"; - silent = true; }; } { mode = "n"; key = "bsr"; - action = ":BufferLineSortByRelativeDirectory"; + action = "BufferLineSortByRelativeDirectory"; options = { desc = "Sort By Relative Directory"; - silent = true; }; } ]; diff --git a/home-manager/modules/neovim/plugins/catppuccin.nix b/home-manager/modules/neovim/plugins/catppuccin.nix index 734a1b9..742d600 100644 --- a/home-manager/modules/neovim/plugins/catppuccin.nix +++ b/home-manager/modules/neovim/plugins/catppuccin.nix @@ -8,7 +8,8 @@ _: { percentage = 0.25; }; - flavour = "macchiato"; + # flavour = "macchiato"; + flavour = "latte"; integrations = { aerial = true; diff --git a/home-manager/modules/neovim/plugins/conform.nix b/home-manager/modules/neovim/plugins/conform.nix index ef095e7..05c4ab0 100644 --- a/home-manager/modules/neovim/plugins/conform.nix +++ b/home-manager/modules/neovim/plugins/conform.nix @@ -43,44 +43,45 @@ plugins = { conform-nvim = { enable = true; - - formatOnSave = - # lua - '' - function(bufnr) - if vim.g.disable_autoformat or vim.b[bufnr].disable_autoformat then - return - end - - if slow_format_filetypes[vim.bo[bufnr].filetype] then - return - end - - local function on_format(err) - if err and err:match("timeout$") then - slow_format_filetypes[vim.bo[bufnr].filetype] = true + settings = { + format_on_save = + # lua + '' + function(bufnr) + if vim.g.disable_autoformat or vim.b[bufnr].disable_autoformat then + return end + + if slow_format_filetypes[vim.bo[bufnr].filetype] then + return + end + + local function on_format(err) + if err and err:match("timeout$") then + slow_format_filetypes[vim.bo[bufnr].filetype] = true + end + end + + return { timeout_ms = 200, lsp_fallback = true }, on_format + end + ''; + + format_after_save = + # lua + '' + function(bufnr) + if vim.g.disable_autoformat or vim.b[bufnr].disable_autoformat then + return + end + + if not slow_format_filetypes[vim.bo[bufnr].filetype] then + return + end + + return { lsp_fallback = true } end - - return { timeout_ms = 200, lsp_fallback = true }, on_format - end - ''; - - formatAfterSave = - # lua - '' - function(bufnr) - if vim.g.disable_autoformat or vim.b[bufnr].disable_autoformat then - return - end - - if not slow_format_filetypes[vim.bo[bufnr].filetype] then - return - end - - return { lsp_fallback = true } - end - ''; + ''; + }; # NOTE: # Conform will run multiple formatters sequentially diff --git a/home-manager/modules/neovim/plugins/default.nix b/home-manager/modules/neovim/plugins/default.nix index 7943ef6..4b17a5f 100644 --- a/home-manager/modules/neovim/plugins/default.nix +++ b/home-manager/modules/neovim/plugins/default.nix @@ -14,16 +14,22 @@ _: { ./git-conflict.nix ./gitsigns.nix ./harpoon.nix + # ./haskell-scope-highlighting.nix ./illuminate.nix + # ./obsidian.nix ./indent-blankline.nix ./lightbulb.nix ./lualine.nix ./luasnip.nix ./lean.nix ./lsp.nix + ./marks.nix + ./mark-radar.nix + ./mini.nix ./mini-bufremove.nix ./mini-surround.nix ./mini-indentscope.nix + ./glow.nix ./navic.nix ./nix.nix ./noice.nix @@ -31,6 +37,7 @@ _: { ./precognition.nix ./spectre.nix ./refactoring.nix + ./render-markdown.nix ./telescope.nix ./todo-comments.nix ./toggleterm.nix diff --git a/home-manager/modules/neovim/plugins/glow.nix b/home-manager/modules/neovim/plugins/glow.nix new file mode 100644 index 0000000..2082566 --- /dev/null +++ b/home-manager/modules/neovim/plugins/glow.nix @@ -0,0 +1,41 @@ +{pkgs, ...}: let + stylePkg = pkgs.fetchFromGitHub { + owner = "catppuccin"; + repo = "glamour"; + rev = "f410083af1e9b2418bcd73dbbbc987461d4aa292"; + hash = "sha256-a7yR19KcxIS4UPhuhB+X0B+s8D5eytw0/EB0X4z46kA="; + }; +in { + programs.nixvim = { + plugins = { + glow = { + enable = true; + + settings = { + border = "single"; + style = "${stylePkg.outPath}/themes/catppuccin-latte.json"; + }; + }; + + which-key.settings.spec = [ + { + __unkeyed = "p"; + mode = "n"; + group = "Preview"; + icon = " "; + } + ]; + }; + + keymaps = [ + { + mode = "n"; + key = "pg"; + action = "Glow"; + options = { + desc = "Glow (Markdown)"; + }; + } + ]; + }; +} diff --git a/home-manager/modules/neovim/plugins/haskell-scope-highlighting.nix b/home-manager/modules/neovim/plugins/haskell-scope-highlighting.nix new file mode 100644 index 0000000..5722587 --- /dev/null +++ b/home-manager/modules/neovim/plugins/haskell-scope-highlighting.nix @@ -0,0 +1,7 @@ +{...}: { + programs.nixvim = { + plugins.haskell-scope-highlighting = { + enable = true; + }; + }; +} diff --git a/home-manager/modules/neovim/plugins/luasnip.nix b/home-manager/modules/neovim/plugins/luasnip.nix index bc8e4db..22d438f 100644 --- a/home-manager/modules/neovim/plugins/luasnip.nix +++ b/home-manager/modules/neovim/plugins/luasnip.nix @@ -15,7 +15,7 @@ fromLua = [{paths = [../snippets];}]; }; extraFiles = { - "personal/luasnip-helper-funcs.lua".text = '' + "lua/personal/luasnip-helper-funcs.lua".text = '' local M = {} local ls = require("luasnip") diff --git a/home-manager/modules/neovim/plugins/mark-radar.nix b/home-manager/modules/neovim/plugins/mark-radar.nix new file mode 100644 index 0000000..dbd74aa --- /dev/null +++ b/home-manager/modules/neovim/plugins/mark-radar.nix @@ -0,0 +1,7 @@ +{...}: { + programs.nixvim = { + plugins.mark-radar = { + enable = true; + }; + }; +} diff --git a/home-manager/modules/neovim/plugins/marks.nix b/home-manager/modules/neovim/plugins/marks.nix new file mode 100644 index 0000000..5a9bad6 --- /dev/null +++ b/home-manager/modules/neovim/plugins/marks.nix @@ -0,0 +1,7 @@ +{...}: { + programs.nixvim = { + plugins.marks = { + enable = true; + }; + }; +} diff --git a/home-manager/modules/neovim/plugins/mini.nix b/home-manager/modules/neovim/plugins/mini.nix new file mode 100644 index 0000000..863b43e --- /dev/null +++ b/home-manager/modules/neovim/plugins/mini.nix @@ -0,0 +1,18 @@ +{...}: { + programs.nixvim = { + plugins.mini = { + enable = true; + mockDevIcons = true; + + modules = { + ai = {}; + align = {}; + basics = {}; + bracketed = {}; + git = {}; + icons = {}; + pairs = {}; + }; + }; + }; +} diff --git a/home-manager/modules/neovim/plugins/obsidian.nix b/home-manager/modules/neovim/plugins/obsidian.nix new file mode 100644 index 0000000..f9e18be --- /dev/null +++ b/home-manager/modules/neovim/plugins/obsidian.nix @@ -0,0 +1,7 @@ +{...}: { + programs.nixvim = { + plugins.obsidian = { + enable = true; + }; + }; +} diff --git a/home-manager/modules/neovim/plugins/precognition.nix b/home-manager/modules/neovim/plugins/precognition.nix index 5d53168..81a6054 100644 --- a/home-manager/modules/neovim/plugins/precognition.nix +++ b/home-manager/modules/neovim/plugins/precognition.nix @@ -5,7 +5,7 @@ keymaps = [ { mode = "n"; - key = "uP"; + key = "vp"; action.__raw = '' function() if require("precognition").toggle() then diff --git a/home-manager/modules/neovim/plugins/render-markdown.nix b/home-manager/modules/neovim/plugins/render-markdown.nix new file mode 100644 index 0000000..c4a9d2c --- /dev/null +++ b/home-manager/modules/neovim/plugins/render-markdown.nix @@ -0,0 +1,9 @@ +{pkgs, ...}: { + programs.nixvim = { + plugins.render-markdown = { + enable = true; + }; + }; + + home.packages = with pkgs; [python312Packages.pylatexenc]; +} diff --git a/home-manager/modules/neovim/plugins/treesitter.nix b/home-manager/modules/neovim/plugins/treesitter.nix index 6b23487..c2e37af 100644 --- a/home-manager/modules/neovim/plugins/treesitter.nix +++ b/home-manager/modules/neovim/plugins/treesitter.nix @@ -7,7 +7,12 @@ settings = { indent.enable = true; - highlight.enable = true; + highlight = { + enable = true; + disable = [ + "latex" + ]; + }; incremental_selection.enable = true; }; }; diff --git a/home-manager/modules/neovim/plugins/vimtex.nix b/home-manager/modules/neovim/plugins/vimtex.nix index 6d20146..8f89dc6 100644 --- a/home-manager/modules/neovim/plugins/vimtex.nix +++ b/home-manager/modules/neovim/plugins/vimtex.nix @@ -3,7 +3,7 @@ plugins.vimtex = { enable = true; settings = { - compiler_method = "latexrun"; + compiler_method = "pdflatex"; toc_config = { split_pos = "vert topleft"; split_width = 40; diff --git a/home-manager/modules/neovim/snippets/tex/delimiter.lua b/home-manager/modules/neovim/snippets/tex/delimiter.lua new file mode 100644 index 0000000..e99989d --- /dev/null +++ b/home-manager/modules/neovim/snippets/tex/delimiter.lua @@ -0,0 +1,92 @@ +local helpers = require("personal.luasnip-helper-funcs") +local get_visual = helpers.get_visual + +-- Math context detection +local tex = {} +tex.in_mathzone = function() + return vim.fn["vimtex#syntax#in_mathzone"]() == 1 +end +tex.in_text = function() + return not tex.in_mathzone() +end + +-- Return snippet tables +return { + -- LEFT/RIGHT PARENTHESES + s( + { trig = "([^%a])l%(", regTrig = true, wordTrig = false, snippetType = "autosnippet" }, + fmta("<>\\left(<>\\right)", { + f(function(_, snip) + return snip.captures[1] + end), + d(1, get_visual), + }) + ), + -- LEFT/RIGHT SQUARE BRACES + s( + { trig = "([^%a])l%[", regTrig = true, wordTrig = false, snippetType = "autosnippet" }, + fmta("<>\\left[<>\\right]", { + f(function(_, snip) + return snip.captures[1] + end), + d(1, get_visual), + }) + ), + -- LEFT/RIGHT CURLY BRACES + s( + { trig = "([^%a])l%{", regTrig = true, wordTrig = false, snippetType = "autosnippet" }, + fmta("<>\\left\\{<>\\right\\}", { + f(function(_, snip) + return snip.captures[1] + end), + d(1, get_visual), + }) + ), + -- BIG PARENTHESES + s( + { trig = "([^%a])b%(", regTrig = true, wordTrig = false, snippetType = "autosnippet" }, + fmta("<>\\big(<>\\big)", { + f(function(_, snip) + return snip.captures[1] + end), + d(1, get_visual), + }) + ), + -- BIG SQUARE BRACES + s( + { trig = "([^%a])b%[", regTrig = true, wordTrig = false, snippetType = "autosnippet" }, + fmta("<>\\big[<>\\big]", { + f(function(_, snip) + return snip.captures[1] + end), + d(1, get_visual), + }) + ), + -- BIG CURLY BRACES + s( + { trig = "([^%a])b%{", regTrig = true, wordTrig = false, snippetType = "autosnippet" }, + fmta("<>\\big\\{<>\\big\\}", { + f(function(_, snip) + return snip.captures[1] + end), + d(1, get_visual), + }) + ), + -- ESCAPED CURLY BRACES + s( + { trig = "([^%a])\\%{", regTrig = true, wordTrig = false, snippetType = "autosnippet", priority = 2000 }, + fmta("<>\\{<>\\}", { + f(function(_, snip) + return snip.captures[1] + end), + d(1, get_visual), + }) + ), + -- LATEX QUOTATION MARK + s( + { trig = "``", snippetType = "autosnippet" }, + fmta("``<>''", { + d(1, get_visual), + }) + ), +} diff --git a/home-manager/modules/neovim/snippets/tex/environments.lua b/home-manager/modules/neovim/snippets/tex/environments.lua new file mode 100644 index 0000000..93d5255 --- /dev/null +++ b/home-manager/modules/neovim/snippets/tex/environments.lua @@ -0,0 +1,221 @@ +local helpers = require("personal.luasnip-helper-funcs") +local get_visual = helpers.get_visual + +-- Math context detection +local tex = {} +tex.in_mathzone = function() + return vim.fn["vimtex#syntax#in_mathzone"]() == 1 +end +tex.in_text = function() + return not tex.in_mathzone() +end + +local line_begin = require("luasnip.extras.expand_conditions").line_begin + +-- Return snippet tables +return { + -- GENERIC ENVIRONMENT + s( + { trig = "new", snippetType = "autosnippet" }, + fmta( + [[ + \begin{<>} + <> + \end{<>} + ]], + { + i(1), + d(2, get_visual), + rep(1), + } + ), + { condition = line_begin } + ), + s( + { trig = "def", snippetType = "autosnippet" }, + fmta( + [[ + \begin{definition}[<>] + <> + \end{definition} + ]], + { + i(1), + d(2, get_visual), + } + ), + { condition = line_begin } + ), + -- ENVIRONMENT WITH ONE EXTRA ARGUMENT + s( + { trig = "n2", snippetType = "autosnippet" }, + fmta( + [[ + \begin{<>}{<>} + <> + \end{<>} + ]], + { + i(1), + i(2), + d(3, get_visual), + rep(1), + } + ), + { condition = line_begin } + ), + -- ENVIRONMENT WITH TWO EXTRA ARGUMENTS + s( + { trig = "n3", snippetType = "autosnippet" }, + fmta( + [[ + \begin{<>}{<>}{<>} + <> + \end{<>} + ]], + { + i(1), + i(2), + i(3), + d(4, get_visual), + rep(1), + } + ), + { condition = line_begin } + ), + -- TOPIC ENVIRONMENT (my custom tcbtheorem environment) + s( + { trig = "nt", snippetType = "autosnippet" }, + fmta( + [[ + \begin{topic}{<>}{<>} + <> + \end{topic} + ]], + { + i(1), + i(2), + d(3, get_visual), + } + ), + { condition = line_begin } + ), + -- EQUATION + s( + { trig = "nn", snippetType = "autosnippet" }, + fmta( + [[ + \begin{equation*} + <> + \end{equation*} + ]], + { + i(1), + } + ), + { condition = line_begin } + ), + -- SPLIT EQUATION + s( + { trig = "ss", snippetType = "autosnippet" }, + fmta( + [[ + \begin{equation*} + \begin{split} + <> + \end{split} + \end{equation*} + ]], + { + d(1, get_visual), + } + ), + { condition = line_begin } + ), + -- ALIGN + s( + { trig = "all", snippetType = "autosnippet" }, + fmta( + [[ + \begin{align*} + <> + \end{align*} + ]], + { + i(1), + } + ), + { condition = line_begin } + ), + -- ITEMIZE + s( + { trig = "itt", snippetType = "autosnippet" }, + fmta( + [[ + \begin{itemize} + + \item <> + + \end{itemize} + ]], + { + i(0), + } + ), + { condition = line_begin } + ), + -- ENUMERATE + s( + { trig = "enn", snippetType = "autosnippet" }, + fmta( + [[ + \begin{enumerate} + + \item <> + + \end{enumerate} + ]], + { + i(0), + } + ) + ), + -- INLINE MATH + s( + { trig = "([^%l])mm", regTrig = true, wordTrig = false, snippetType = "autosnippet" }, + fmta("<>$<>$", { + f(function(_, snip) + return snip.captures[1] + end), + d(1, get_visual), + }) + ), + -- INLINE MATH ON NEW LINE + s( + { trig = "^mm", regTrig = true, wordTrig = false, snippetType = "autosnippet" }, + fmta("$<>$", { + i(1), + }) + ), + -- FIGURE + s( + { trig = "fig" }, + fmta( + [[ + \begin{figure}[htb!] + \centering + \includegraphics[width=<>\linewidth]{<>} + \caption{<>} + \label{fig:<>} + \end{figure} + ]], + { + i(1), + i(2), + i(3), + i(4), + } + ), + { condition = line_begin } + ), +} diff --git a/home-manager/modules/neovim/snippets/tex/fonts.lua b/home-manager/modules/neovim/snippets/tex/fonts.lua new file mode 100644 index 0000000..49bb1eb --- /dev/null +++ b/home-manager/modules/neovim/snippets/tex/fonts.lua @@ -0,0 +1,106 @@ +local helpers = require("personal.luasnip-helper-funcs") +local get_visual = helpers.get_visual + +-- A logical OR of `line_begin` and the regTrig '[^%a]trig' +function line_begin_or_non_letter(line_to_cursor, matched_trigger) + local line_begin = line_to_cursor:sub(1, -(#matched_trigger + 1)):match("^%s*$") + local non_letter = line_to_cursor:sub(-(#matched_trigger + 1), -(#matched_trigger + 1)):match("[^%a]") + return line_begin or non_letter +end + +-- Math context detection +local tex = {} +tex.in_mathzone = function() + return vim.fn["vimtex#syntax#in_mathzone"]() == 1 +end +tex.in_text = function() + return not tex.in_mathzone() +end + +local line_begin = function(line_to_cursor, matched_trigger) + -- +1 because `string.sub("abcd", 1, -2)` -> abc + return line_to_cursor:sub(1, -(#matched_trigger + 1)):match("^%s*$") +end + +-- Return snippet tables +return { + -- TYPEWRITER i.e. \texttt + s( + { trig = "([^%a])tt", regTrig = true, wordTrig = false, snippetType = "autosnippet", priority = 2000 }, + fmta("<>\\texttt{<>}", { + f(function(_, snip) + return snip.captures[1] + end), + d(1, get_visual), + }), + { condition = tex.in_text } + ), + -- ITALIC i.e. \textit + s( + { trig = "([^%a])tii", regTrig = true, wordTrig = false, snippetType = "autosnippet" }, + fmta("<>\\textit{<>}", { + f(function(_, snip) + return snip.captures[1] + end), + d(1, get_visual), + }) + ), + -- BOLD i.e. \textbf + s( + { trig = "tbb", snippetType = "autosnippet" }, + fmta("\\textbf{<>}", { + d(1, get_visual), + }) + ), + -- MATH ROMAN i.e. \mathrm + s( + { trig = "([^%a])rmm", regTrig = true, wordTrig = false, snippetType = "autosnippet" }, + fmta("<>\\mathrm{<>}", { + f(function(_, snip) + return snip.captures[1] + end), + d(1, get_visual), + }) + ), + -- MATH CALIGRAPHY i.e. \mathcal + s( + { trig = "([^%a])mcc", regTrig = true, wordTrig = false, snippetType = "autosnippet" }, + fmta("<>\\mathcal{<>}", { + f(function(_, snip) + return snip.captures[1] + end), + d(1, get_visual), + }) + ), + -- MATH BOLDFACE i.e. \mathbf + s( + { trig = "([^%a])mbf", regTrig = true, wordTrig = false, snippetType = "autosnippet" }, + fmta("<>\\mathbf{<>}", { + f(function(_, snip) + return snip.captures[1] + end), + d(1, get_visual), + }) + ), + -- MATH BLACKBOARD i.e. \mathbb + s( + { trig = "([^%a])mbb", regTrig = true, wordTrig = false, snippetType = "autosnippet" }, + fmta("<>\\mathbb{<>}", { + f(function(_, snip) + return snip.captures[1] + end), + d(1, get_visual), + }) + ), + -- REGULAR TEXT i.e. \text (in math environments) + s( + { trig = "([^%a])tee", regTrig = true, wordTrig = false, snippetType = "autosnippet" }, + fmta("<>\\text{<>}", { + f(function(_, snip) + return snip.captures[1] + end), + d(1, get_visual), + }), + { condition = tex.in_mathzone } + ), +} diff --git a/home-manager/modules/neovim/snippets/tex/luatex.lua b/home-manager/modules/neovim/snippets/tex/luatex.lua new file mode 100644 index 0000000..c845673 --- /dev/null +++ b/home-manager/modules/neovim/snippets/tex/luatex.lua @@ -0,0 +1,19 @@ +local helpers = require("personal.luasnip-helper-funcs") +local get_visual = helpers.get_visual +local line_begin = require("luasnip.extras.expand_conditions").line_begin + +-- Return snippet tables +return { + -- tex.sprint + s( + { trig = "tpp", snippetType = "autosnippet" }, + fmta( + [[ + tex.sprint(<>) + ]], + { + d(1, get_visual), + } + ) + ), +} diff --git a/home-manager/modules/neovim/snippets/tex/math.lua b/home-manager/modules/neovim/snippets/tex/math.lua index 3cc37da..a97dace 100644 --- a/home-manager/modules/neovim/snippets/tex/math.lua +++ b/home-manager/modules/neovim/snippets/tex/math.lua @@ -1,8 +1,12 @@ local helpers = require("personal.luasnip-helper-funcs") local get_visual = helpers.get_visual - +local ls = require("luasnip") +local sn = ls.snippet_node +local t = ls.text_node +local r = ls.restore_node -- Math context detection local tex = {} +-- local function in_mathzone() return vim.api.nvim_eval('vimtex#syntax#in_mathzone()') == 1 end tex.in_mathzone = function() return vim.fn["vimtex#syntax#in_mathzone"]() == 1 end @@ -10,8 +14,31 @@ tex.in_text = function() return not tex.in_mathzone() end +tex.generate_matrix = function(args, snip) + local rows = tonumber(snip.captures[2]) + local cols = tonumber(snip.captures[3]) + local nodes = {} + local ins_indx = 1 + for j = 1, rows do + table.insert(nodes, r(ins_indx, tostring(j) .. "x1", i(1))) + ins_indx = ins_indx + 1 + for k = 2, cols do + table.insert(nodes, t(" & ")) + table.insert(nodes, r(ins_indx, tostring(j) .. "x" .. tostring(k), i(1))) + ins_indx = ins_indx + 1 + end + table.insert(nodes, t({ "\\\\", "" })) + end + -- fix last node. + nodes[#nodes] = t("\\\\") + return sn(nil, nodes) +end + -- Return snippet tables return { + s({ trig = "vton", snippetType = "autosnippet" }, { + t("\\vec{v}_1, \\cdots, \\vec{v}_n"), + }), -- SUPERSCRIPT s( { trig = "([%w%)%]%}])'", wordTrig = false, regTrig = true, snippetType = "autosnippet" }, @@ -397,6 +424,15 @@ return { }), { condition = tex.in_mathzone } ), + + -- { trig = "([^%a])lim", wordTrig = false, regTrig = true, snippetType = "autosnippet" }, + -- fmta("<>\\lim_{<>}", { + -- f(function(_, snip) + -- return snip.captures[1] + -- end), + -- }), + -- { condition = tex.in_mathzone } + -- ), -- -- BEGIN STATIC SNIPPETS -- @@ -489,4 +525,36 @@ return { s({ trig = "xx", snippetType = "autosnippet" }, { t("\\times "), }), + s( + { + trig = "([bBpvV])mat(%d+)x(%d+)([ar])", + name = "[bBpvV]matrix", + dscr = "matrices", + regTrig = true, + hidden = true, + }, + fmta( + [[ + \begin{<>}<> + <> + \end{<>}]], + { + f(function(_, snip) + return snip.captures[1] .. "matrix" + end), + f(function(_, snip) + if snip.captures[4] == "a" then + out = string.rep("c", tonumber(snip.captures[3]) - 1) + return "[" .. out .. "|c]" + end + return "" + end), + d(1, tex.generate_matrix), + f(function(_, snip) + return snip.captures[1] .. "matrix" + end), + } + ), + { condition = tex.in_math, show_condition = tex.in_math } + ), } diff --git a/home-manager/modules/neovim/snippets/tex/static.lua b/home-manager/modules/neovim/snippets/tex/static.lua new file mode 100644 index 0000000..0540f4b --- /dev/null +++ b/home-manager/modules/neovim/snippets/tex/static.lua @@ -0,0 +1,58 @@ +local helpers = require("personal.luasnip-helper-funcs") +local get_visual = helpers.get_visual + +local line_begin = require("luasnip.extras.expand_conditions").line_begin + +-- Environment/syntax context detection +local tex = {} +tex.in_mathzone = function() + return vim.fn["vimtex#syntax#in_mathzone"]() == 1 +end +tex.in_text = function() + return not tex.in_mathzone() +end +tex.in_tikz = function() + local is_inside = vim.fn["vimtex#env#is_inside"]("tikzpicture") + return (is_inside[1] > 0 and is_inside[2] > 0) +end + +-- Return snippet tables +return { + s({ trig = "q" }, { + t("\\quad "), + }), + s({ trig = "qq", snippetType = "autosnippet" }, { + t("\\qquad "), + }), + s({ trig = "npp", snippetType = "autosnippet" }, { + t({ "\\newpage", "" }), + }, { condition = line_begin }), + s({ trig = "which", snippetType = "autosnippet" }, { + t("\\text{ for which } "), + }, { condition = tex.in_mathzone }), + s({ trig = "all", snippetType = "autosnippet" }, { + t("\\text{ for all } "), + }, { condition = tex.in_mathzone }), + s({ trig = "and", snippetType = "autosnippet" }, { + t("\\quad \\text{and} \\quad"), + }, { condition = tex.in_mathzone }), + s({ trig = "forall", snippetType = "autosnippet" }, { + t("\\text{ for all } "), + }, { condition = tex.in_mathzone }), + s({ trig = "toc", snippetType = "autosnippet" }, { + t("\\tableofcontents"), + }, { condition = line_begin }), + s({ trig = "inff", snippetType = "autosnippet" }, { + t("\\infty"), + }), + s({ trig = "ii", snippetType = "autosnippet" }, { + t("\\item "), + }, { condition = line_begin }), + s( + { trig = "--", snippetType = "autosnippet" }, + { t("% --------------------------------------------- %") }, + { condition = line_begin } + ), + -- HLINE WITH EXTRA VERTICAL SPACE + s({ trig = "hl" }, { t("\\hline {\\rule{0pt}{2.5ex}} \\hspace{-7pt}") }, { condition = line_begin }), +} diff --git a/home-manager/modules/neovim/snippets/tex/system.lua b/home-manager/modules/neovim/snippets/tex/system.lua new file mode 100644 index 0000000..506d385 --- /dev/null +++ b/home-manager/modules/neovim/snippets/tex/system.lua @@ -0,0 +1,192 @@ +local helpers = require("personal.luasnip-helper-funcs") +local get_visual = helpers.get_visual + +local line_begin = require("luasnip.extras.expand_conditions").line_begin + +-- Math context detection +local tex = {} +tex.in_mathzone = function() + return vim.fn["vimtex#syntax#in_mathzone"]() == 1 +end +tex.in_text = function() + return not tex.in_mathzone() +end + +-- Return snippet tables +return { + -- ANNOTATE (custom command for annotating equation derivations) + s( + { trig = "ann", snippetType = "autosnippet" }, + fmta( + [[ + \annotate{<>}{<>} + ]], + { + i(1), + d(2, get_visual), + } + ) + ), + -- REFERENCE + s( + { trig = " RR", snippetType = "autosnippet", wordTrig = false }, + fmta( + [[ + ~\ref{<>} + ]], + { + d(1, get_visual), + } + ) + ), + -- DOCUMENTCLASS + s( + { trig = "dcc", snippetType = "autosnippet" }, + fmta( + [=[ + \documentclass[<>]{<>} + ]=], + { + i(1, "a4paper"), + i(2, "article"), + } + ), + { condition = line_begin } + ), + -- USE A LATEX PACKAGE + s( + { trig = "pack", snippetType = "autosnippet" }, + fmta( + [[ + \usepackage{<>} + ]], + { + d(1, get_visual), + } + ), + { condition = line_begin } + ), + -- INPUT a LaTeX file + s( + { trig = "inn", snippetType = "autosnippet" }, + fmta( + [[ + \input{<><>} + ]], + { + i(1, "~/dotfiles/config/latex/templates/"), + i(2), + } + ), + { condition = line_begin } + ), + -- LABEL + s( + { trig = "lbl", snippetType = "autosnippet" }, + fmta( + [[ + \label{<>} + ]], + { + d(1, get_visual), + } + ) + ), + -- HPHANTOM + s( + { trig = "hpp", snippetType = "autosnippet" }, + fmta( + [[ + \hphantom{<>} + ]], + { + d(1, get_visual), + } + ) + ), + s( + { trig = "TODOO", snippetType = "autosnippet" }, + fmta([[\TODO{<>}]], { + d(1, get_visual), + }) + ), + s( + { trig = "nc" }, + fmta([[\newcommand{<>}{<>}]], { + i(1), + i(2), + }), + { condition = line_begin } + ), + s( + { trig = "sii", snippetType = "autosnippet" }, + fmta([[\si{<>}]], { + i(1), + }) + ), + s( + { trig = "qtt" }, + fmta([[\qty{<>}{<>}]], { + i(1), + i(2), + }) + ), + -- URL + s( + { trig = "url" }, + fmta([[\url{<>}]], { + d(1, get_visual), + }) + ), + -- href command with URL in visual selection + s( + { trig = "LU", snippetType = "autosnippet" }, + fmta([[\href{<>}{<>}]], { + d(1, get_visual), + i(2), + }) + ), + -- href command with text in visual selection + s( + { trig = "LL", snippetType = "autosnippet" }, + fmta([[\href{<>}{<>}]], { + i(1), + d(2, get_visual), + }) + ), + -- HSPACE + s( + { trig = "hss", snippetType = "autosnippet" }, + fmta([[\hspace{<>}]], { + d(1, get_visual), + }) + ), + -- VSPACE + s( + { trig = "vss", snippetType = "autosnippet" }, + fmta([[\vspace{<>}]], { + d(1, get_visual), + }) + ), + -- SECTION + s( + { trig = "h1", snippetType = "autosnippet" }, + fmta([[\section{<>}]], { + d(1, get_visual), + }) + ), + -- SUBSECTION + s( + { trig = "h2", snippetType = "autosnippet" }, + fmta([[\subsection{<>}]], { + d(1, get_visual), + }) + ), + -- SUBSUBSECTION + s( + { trig = "h3", snippetType = "autosnippet" }, + fmta([[\subsubsection{<>}]], { + d(1, get_visual), + }) + ), +} diff --git a/home-manager/modules/neovim/snippets/tex/test.tex b/home-manager/modules/neovim/snippets/tex/test.tex deleted file mode 100644 index a1a72cb..0000000 --- a/home-manager/modules/neovim/snippets/tex/test.tex +++ /dev/null @@ -1,5 +0,0 @@ - - -\begin{align*} - -\end{align*} diff --git a/home-manager/modules/neovim/snippets/tex/tmp.lua b/home-manager/modules/neovim/snippets/tex/tmp.lua new file mode 100644 index 0000000..271524a --- /dev/null +++ b/home-manager/modules/neovim/snippets/tex/tmp.lua @@ -0,0 +1,84 @@ +local helpers = require("personal.luasnip-helper-funcs") +local get_visual = helpers.get_visual + +local line_begin = require("luasnip.extras.expand_conditions").line_begin + +-- Math context detection +local tex = {} +tex.in_mathzone = function() + return vim.fn["vimtex#syntax#in_mathzone"]() == 1 +end +tex.in_text = function() + return not tex.in_mathzone() +end + +return { + + -- Equation, choice for labels + s( + { + trig = "beq", + dscr = "Expands 'beq' into an equation environment, with a choice for labels", + snippetType = "autosnippet", + }, + fmta( + [[ + \begin{equation}<> + <> + \end{equation} + ]], + { + c(1, { + sn( + 2, -- Choose to specify an equation label + { + t("\\label{eq:"), + i(1), + t("}"), + } + ), + t([[]]), -- Choose no label + }, {}), + i(2), + } + ) + ), + + -- Figure environment + s( + { trig = "foofig", dscr = "Use 'fig' for figure environmennt, with options" }, + fmta( + [[ + \begin{figure}<> + \centering + \includegraphics<>{<>} + \caption{<>} + \label{fig:<>} + \end{figure} + ]], + { + -- Optional [htbp] field + c(1, { + t([[]]), -- Choice 1, empty + t("[htbp]"), -- Choice 2, this may be turned into a snippet + }, {}), + -- Options for includegraphics + c(2, { + t([[]]), -- Choice 1, empty + sn( + 3, -- Choice 2, this may be turned into a snippet + { + t("[width="), + i(1), + t("\\textwidth]"), + } + ), + }, {}), + i(3, "filename"), + i(4, "text"), + i(5, "label"), + } + ), + { condition = line_begin } + ), +} diff --git a/home-manager/modules/zsh.nix b/home-manager/modules/zsh.nix index 088c82c..c8f76f5 100644 --- a/home-manager/modules/zsh.nix +++ b/home-manager/modules/zsh.nix @@ -10,6 +10,7 @@ shellAliases = { update = "sudo nixos-rebuild switch"; clean = "nix-collect-garbage -d"; + repair = "nix-store --repair --verify --check-contents"; reload = "source ~/.zshrc"; "." = "cd ../"; diff --git a/hosts/grymforge/configuration.nix b/hosts/grymforge/configuration.nix index fe24371..fcff151 100644 --- a/hosts/grymforge/configuration.nix +++ b/hosts/grymforge/configuration.nix @@ -23,6 +23,8 @@ ../../common/networking ../../common/virtualization + ../../common/nixos + ../../common/gui ./syncthing.nix ./auditd.nix @@ -46,6 +48,7 @@ ssh.enable = true; ssh_guard.enable = true; nfs.enable = true; + steam.enable = true; # Bootloader. boot = { diff --git a/hosts/grymforge/kernel.nix b/hosts/grymforge/kernel.nix index 9096e08..23d8d3b 100644 --- a/hosts/grymforge/kernel.nix +++ b/hosts/grymforge/kernel.nix @@ -1,9 +1,4 @@ -{ - config, - pkgs, - stdenv, - ... -}: { +{pkgs, ...}: { boot.kernelPackages = pkgs.linuxPackages_hardened; boot.kernelParams = [ # Disable slab merging to prevent heap exploitation diff --git a/secrets/secrets.yaml b/secrets/secrets.yaml index ab2c479..75e6ca6 100644 --- a/secrets/secrets.yaml +++ b/secrets/secrets.yaml @@ -1,5 +1,6 @@ restic_key: ENC[AES256_GCM,data:DzpWvFP5gyhrnLVIYgu9ouotWqkOAHehihSKf/TqJE+sHTD4vnIScfhzoKzdkoDoWfkcmQ==,iv:q83qNYuP/3mngvg+kUfOVToogL8VTvZ6HiGIztpnP/s=,tag:YNWwbma0HmPKqYCS1L5kQQ==,type:str] -wireless.env: ENC[AES256_GCM,data:LzvMh6lfM9pnS3joSK3SUqEZDfP+Qk7NQmROWny1XhvQ0SkihvlM40YgA4ZGtwcPO1OnrDy6Srfvy+fuOqqt1XEK6qIOSir6cODkGQbKBa1Ui347P28tw6hgEHM57EYTAfMMwaHTtglPAvN/7YvdMPMT+EwcoyCzj5efRR6pZ0FeLSOtzKeYwe4oaRX1MP+THooSzw+zuoGmU6x3Dq4E8hruFd2o0ug3OEj2r95LVmGnnUiiLxU8YhDd+PXXyz8T6fFdapN1,iv:pdXqMqiR3qEQG1LvXqXWB8vpM6d2/Curv4gvuLOOatI=,tag:7H2wST9Mx9C3RCsOeUD1Vw==,type:str] +wireless.env: ENC[AES256_GCM,data:/5i0Kv+VFTtVpaD7tfO2ahePu20eYkUYAqoh39PA2aoMWywLddQEQy4arj2Nvcw8hsRk760Kiq4wz3c23dPDqy7rU980NF2RaP4ODMIiQISfYeQP9coD84JhlnSTW+7EkhV520naqJgIYY0IsA8OxR/5euyFMHOL75FKnBh1ILY2DPSsJNG2m2ldw+US7E+7r4REl8tDqKfCIL5tznmbVTbPrer7cwrXe+ScFaholmqSntaB06yIIO3yr88TmE6EXF6oLCXU,iv:DPOqx7M7E83+DYjGFPZy44cxrta/3953IDjXL40rLAc=,tag:KmYBpQKgshMSgxnC96T1bQ==,type:str] +home_uuid: ENC[AES256_GCM,data:VX92mQuoYXpPxe6EzQ==,iv:3i7Ll7rITrOTYMKK4tHy+IU5DVWFbFjrFHQ3uw3Gr7g=,tag:0bp/XaR4JOdFYpSVtpxm5A==,type:str] sops: kms: [] gcp_kms: [] @@ -15,8 +16,8 @@ sops: US9oa0pORXRVWWlyYlZZTGhXdTdOaWsKClqIK/YNJIIGFqOO0t4oni8dRTTXQniG ioIwAOdEgE/n0vcYhHXxLxWlTeqGZF076g7EFfIqiSNqrDtacRnazg== -----END AGE ENCRYPTED FILE----- - lastmodified: "2024-09-13T19:21:22Z" - mac: ENC[AES256_GCM,data:dzWc9v24u1tT8ZeVCXawKn3IovFxlfs6B8yrgzkn7rZGtZDN5iAwTStuZtRYW8tydNuY7KZa9dH/9+Eh7YW9iGsumzQ3ewCHCyg9kdBpC9yGGDkIw41mKG3aweFERtXfq0WWnqDHnr7ZGrtPfsEOxvMG+uKU7K3lslhlcyeQf+U=,iv:BNXwcKP5vOHxbKX8fD3lbEuzhuHqAI5qi8mXtleG6p4=,tag:7WPAxw8IfE+flxzAentE6Q==,type:str] + lastmodified: "2024-10-03T04:35:54Z" + mac: ENC[AES256_GCM,data:6h43edjI9ouW2vbTcydrvbrqDb7GmMVgXBUk8nHyd0mV5QzR0ZeGzl+WXN5cwTRqwahAMsFax6riWyCFyMAEHIC66ucQhhPKH90vsKpm7/Nh037lbIfbYnqVG5PTdRzLo0zELkNmB5NX7j0amgynEX3xm1ipcWPGowTQiVjkQ98=,iv:zsVRb2ahPZ27hOkdhjmDl3px0wBri+xIwSvya2Kg8Hg=,tag:qrDuyDrIfccOnvqekiNnWA==,type:str] pgp: [] unencrypted_suffix: _unencrypted version: 3.9.0 diff --git a/wallpapers/nixos-wallpaper-catppuccin-latte.png b/wallpapers/nixos-wallpaper-catppuccin-latte.png new file mode 100644 index 0000000..243c569 Binary files /dev/null and b/wallpapers/nixos-wallpaper-catppuccin-latte.png differ