From dae3149a93cab4d1140526e15eb928d275f56128 Mon Sep 17 00:00:00 2001 From: Azat Bahawi Date: Fri, 7 Apr 2023 19:35:15 +0300 Subject: 2023-04-07 --- flake.lock | 66 +++++++++++++++++------------------ modules/common/common/nix/default.nix | 2 +- modules/common/profiles/email.nix | 22 ++++++++++-- modules/common/subversion.nix | 2 +- modules/nixos/games/gamemode.nix | 8 ++++- modules/nixos/games/lutris.nix | 10 +----- modules/nixos/mpd.nix | 2 ++ 7 files changed, 64 insertions(+), 48 deletions(-) diff --git a/flake.lock b/flake.lock index f14ca60..31fe897 100644 --- a/flake.lock +++ b/flake.lock @@ -10,11 +10,11 @@ ] }, "locked": { - "lastModified": 1677969766, - "narHash": "sha256-AIp/ZYZMNLDZR/H7iiAlaGpu4lcXsVt9JQpBlf43HRY=", + "lastModified": 1680281360, + "narHash": "sha256-XdLTgAzjJNDhAG2V+++0bHpSzfvArvr2pW6omiFfEJk=", "owner": "ryantm", "repo": "agenix", - "rev": "03b51fe8e459a946c4b88dcfb6446e45efb2c24e", + "rev": "e64961977f60388dd0b49572bb0fc453b871f896", "type": "github" }, "original": { @@ -121,11 +121,11 @@ ] }, "locked": { - "lastModified": 1673295039, - "narHash": "sha256-AsdYgE8/GPwcelGgrntlijMg4t3hLFJFCRF3tL5WVjA=", + "lastModified": 1680266963, + "narHash": "sha256-IW/lzbUCOcldLHWHjNSg1YoViDnZOmz0ZJL7EH9OkV8=", "owner": "LnL7", "repo": "nix-darwin", - "rev": "87b9d090ad39b25b2400029c64825fc2a8868943", + "rev": "99d4187d11be86b49baa3a1aec0530004072374f", "type": "github" }, "original": { @@ -195,11 +195,11 @@ }, "flake-utils": { "locked": { - "lastModified": 1678901627, - "narHash": "sha256-U02riOqrKKzwjsxc/400XnElV+UtPUQWpANPlyazjH0=", + "lastModified": 1680776469, + "narHash": "sha256-3CXUDK/3q/kieWtdsYpDOBJw3Gw4Af6x+2EiSnIkNQw=", "owner": "numtide", "repo": "flake-utils", - "rev": "93a2b84fc4b70d9e089d029deacc3583435c2ed6", + "rev": "411e8764155aa9354dbcd6d5faaeb97e9e3dce24", "type": "github" }, "original": { @@ -240,11 +240,11 @@ ] }, "locked": { - "lastModified": 1680114304, - "narHash": "sha256-XymtLu8G2nzenjDUWI7XV2MMHztvPkEZUFpwmZFcxVM=", + "lastModified": 1680667162, + "narHash": "sha256-2vgxK4j42y73S3XB2cThz1dSEyK9J9tfu4mhuEfAw68=", "owner": "nix-community", "repo": "home-manager", - "rev": "0e065e1b6f0776ebbacea9dcbc977af7bc9eddc0", + "rev": "440faf5ae472657ef2d8cc7756d77b6ab0ace68d", "type": "github" }, "original": { @@ -296,11 +296,11 @@ ] }, "locked": { - "lastModified": 1680140339, - "narHash": "sha256-P5rexqb5iOiRQFfqJj8YItgG0B5rKncEZJHJPRcTYQI=", + "lastModified": 1680830495, + "narHash": "sha256-w7JCznnip3HcuviaSHRsSuMBTTSNBkEoS8NaYP0EE/E=", "owner": "Infinidoge", "repo": "nix-minecraft", - "rev": "9c6b1d8bab44b77bc19f201c472b73a2ce4f7dad", + "rev": "7407f3287a8e1f51b03d7a4de327c9ff318de0b9", "type": "github" }, "original": { @@ -312,11 +312,11 @@ }, "nixos-hardware": { "locked": { - "lastModified": 1680070330, - "narHash": "sha256-aoT2YZCd9LEtiEULFLIF0ykKydgE72X8gw/k9/pRS5I=", + "lastModified": 1680876084, + "narHash": "sha256-eP9yxP0wc7XuVaODugh+ajgbFGaile2O1ihxiLxOuvU=", "owner": "NixOS", "repo": "nixos-hardware", - "rev": "a6aa8174fa61e55bd7e62d35464d3092aefe0421", + "rev": "3006d2860a6ed5e01b0c3e7ffb730e9b293116e2", "type": "github" }, "original": { @@ -328,11 +328,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1680121753, - "narHash": "sha256-rB3ZnNodA4o8Rq0sKZ0t/YdY/MRon4V+bW1b20adgr4=", + "lastModified": 1680819799, + "narHash": "sha256-zuHl2LNr1Bll64zfr7805Yvvu23S1e//5Up0oqvjknY=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "e779e17ebdf3907ce08c75c7c1b2dc8a1c5038c9", + "rev": "144133c526040a5140e89366ff72ac2d387e9bbb", "type": "github" }, "original": { @@ -344,11 +344,11 @@ }, "nixpkgs-master": { "locked": { - "lastModified": 1680186142, - "narHash": "sha256-Ypjc8vzstTbxJhSkaNQcRUXuE0NeNKqBHMaYr2F887Y=", + "lastModified": 1680882415, + "narHash": "sha256-trt2pwLDu1+kEtp3bx2DiYgg8CFWNbes+ujdAtSBO/U=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "f13bb7efd2b6eefb3bb8b62b3159f888f0264985", + "rev": "cd07e0258cf73e1bcbd0c9abc5513baa091ee801", "type": "github" }, "original": { @@ -360,11 +360,11 @@ }, "nixpkgs-stable": { "locked": { - "lastModified": 1680183455, - "narHash": "sha256-lhlRyEZE1CZ2B5h4goEbS3Env7G6ORojj0/+AAGOooM=", + "lastModified": 1680879128, + "narHash": "sha256-ISFCCZ3/Dw5WK/6kFKwqA6gIEaOjqU/5NoB6Vge87sE=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "646930ff24273c6d91fb3ea37531261553043b50", + "rev": "fa98075869eb8264052548dde5c2ce9e68cf4cf1", "type": "github" }, "original": { @@ -410,11 +410,11 @@ }, "nur": { "locked": { - "lastModified": 1680183987, - "narHash": "sha256-ww5/H0ZmV8ztnrDaL7GX2zLW82yURgrTebGEd4nTx6Y=", + "lastModified": 1680878697, + "narHash": "sha256-CKdUnm3Nuh0rWLXq9p/FHTop7SkYOO+4XRgRGumxc0M=", "owner": "nix-community", "repo": "NUR", - "rev": "fa953d3867d6f133eb4d72234d8dd0fa68d007e0", + "rev": "e3157bf0c8429092a4b84e45504ed8e3efb3a8d3", "type": "github" }, "original": { @@ -466,11 +466,11 @@ ] }, "locked": { - "lastModified": 1680170909, - "narHash": "sha256-FtKU/edv1jFRr/KwUxWTYWXEyj9g8GBrHntC2o8oFI8=", + "lastModified": 1680865110, + "narHash": "sha256-SOBuUZe+icM5zqeEBGRY/fM6BDanEySw4Ph9TQgC3MY=", "owner": "cachix", "repo": "pre-commit-hooks.nix", - "rev": "29dbe1efaa91c3a415d8b45d62d48325a4748816", + "rev": "a6a5e1fa5327a8809c51bc6c69407b8a76f1a4ec", "type": "github" }, "original": { diff --git a/modules/common/common/nix/default.nix b/modules/common/common/nix/default.nix index c06296d..dc73d68 100644 --- a/modules/common/common/nix/default.nix +++ b/modules/common/common/nix/default.nix @@ -99,7 +99,7 @@ with lib; { patches = [./patches/alejandra-no-ads.patch]; }); - inherit (pkgsPR "224461" "sha256-5+GjqIYkHXfOFRFOZUiy+/OJ0USHrDp5vJebv3XErbw=") ntfy-sh; + inherit (pkgsPR "225109" "sha256-aLQcBwo2y92bn/nugidJtFCCEdkNOkSsTeoZ5B2Qt1c=") libvlc; } // (with super; let np = nodePackages; diff --git a/modules/common/profiles/email.nix b/modules/common/profiles/email.nix index e289c2e..9cc12d7 100644 --- a/modules/common/profiles/email.nix +++ b/modules/common/profiles/email.nix @@ -39,7 +39,18 @@ in { attrs ]; - pass = path: "${config.hm.programs.password-store.package}/bin/pass show ${path}"; + getPassword = { + path, + line ? 0, + }: + assert (builtins.isInt line); + concatStringsSep " " ( + [ + "${config.hm.programs.password-store.package}/bin/pass show ${path}" + ] + ++ optional (line > 0) + "| ${pkgs.gnused}/bin/sed -e '${toString line}!d'" + ); in rec { shire = mkAccount rec { address = my.email; @@ -64,7 +75,9 @@ in { tls.enable = true; }; userName = "azahi@shire.net"; - passwordCommand = pass "email/shire.net/azahi"; + passwordCommand = getPassword { + path = "email/shire.net/azahi"; + }; }; yahoo = mkAccount rec { @@ -74,7 +87,10 @@ in { flavor = "yahoo.com"; userName = "admin@yahoo.com"; - passwordCommand = pass "email/yahoo.com/admin"; + passwordCommand = getPassword { + path = "email/yahoo.com/admin"; + line = 2; + }; }; }; }; diff --git a/modules/common/subversion.nix b/modules/common/subversion.nix index 077f449..40ea07d 100644 --- a/modules/common/subversion.nix +++ b/modules/common/subversion.nix @@ -46,7 +46,7 @@ in { }; }; - packages = with pkgs; [(subversionClient.override {saslSupport = true;})]; + packages = [(pkgs.subversionClient.override {saslSupport = true;})]; }; }; } diff --git a/modules/nixos/games/gamemode.nix b/modules/nixos/games/gamemode.nix index 051d12e..193a764 100644 --- a/modules/nixos/games/gamemode.nix +++ b/modules/nixos/games/gamemode.nix @@ -9,5 +9,11 @@ in { options.nixfiles.modules.games.gamemode.enable = mkEnableOption "Feral GameMode"; - config = mkIf cfg.enable {programs.gamemode.enable = true;}; + config = mkIf cfg.enable { + hm.xdg.configFile."gamemode.ini".text = generators.toINI {} { + general.softrealtime = "auto"; + }; + + programs.gamemode.enable = true; + }; } diff --git a/modules/nixos/games/lutris.nix b/modules/nixos/games/lutris.nix index 2737953..ad1e43e 100644 --- a/modules/nixos/games/lutris.nix +++ b/modules/nixos/games/lutris.nix @@ -17,15 +17,7 @@ in { }; hm.home.packages = with pkgs; [ - (lutris.override { - lutris-unwrapped = lutris-unwrapped.override { - wine = buildFHSUserEnv { - # We don't really need Wine because Lutris downloads a required - # runtime for us. - name = "empty"; - }; - }; - }) + lutris vkBasalt winetricks ]; diff --git a/modules/nixos/mpd.nix b/modules/nixos/mpd.nix index 7540c14..b38ab9f 100644 --- a/modules/nixos/mpd.nix +++ b/modules/nixos/mpd.nix @@ -41,7 +41,9 @@ in { settings = rec { ncmpcpp_directory = "${config.dirs.data}/ncmpcpp"; + lyrics_directory = "${ncmpcpp_directory}/lyrics"; + lyrics_fetchers = "musixmatch, genius, internet"; playlist_disable_highlight_delay = 1; message_delay_time = 1; -- cgit 1.4.1