From 7e3af142041e3246b35bd46fc204e8dbe1fc277b Mon Sep 17 00:00:00 2001 From: Yusuf Bera Ertan Date: Sat, 30 Jul 2022 03:04:32 +0300 Subject: [PATCH] guh --- flake.lock | 6 +++--- hosts/tkaronto/default.nix | 31 ++++++++++++++++------------ modules/base/hm-system-defaults.nix | 1 + modules/base/nix.nix | 5 +++++ pkgs-set/overlays/helix.nix | 7 ++++++- pkgs-set/overlays/steam.nix | 8 +++---- secrets/default.nix | Bin 248 -> 642 bytes users/patriot/default.nix | 13 ++++++++---- 8 files changed, 46 insertions(+), 25 deletions(-) diff --git a/flake.lock b/flake.lock index a7deef2..7828d1f 100644 --- a/flake.lock +++ b/flake.lock @@ -135,11 +135,11 @@ "rust-overlay": "rust-overlay" }, "locked": { - "lastModified": 1657470464, - "narHash": "sha256-eMA+/7XzUJpCuDJZRPc/0OMWA6CNisDLSZh3bFYCybo=", + "lastModified": 1659072681, + "narHash": "sha256-vvdQHhnJIxrIh8phbJRM/h8GgZBXj7Lc9yK05t52yCg=", "owner": "helix-editor", "repo": "helix", - "rev": "0cb0c306183be94b9d42c3fae22b805850f87584", + "rev": "a8b123fe177d8cd7f5a610a0a50c16c9f64069bd", "type": "github" }, "original": { diff --git a/hosts/tkaronto/default.nix b/hosts/tkaronto/default.nix index bbaaf2b..ddfea82 100644 --- a/hosts/tkaronto/default.nix +++ b/hosts/tkaronto/default.nix @@ -4,11 +4,9 @@ pkgs, inputs, ... -}: -let +}: let byLabel = label: "/dev/disk/by-label/${label}"; -in -{ +in { imports = with inputs; with nixos-hardware.nixosModules; [ nixpkgs.nixosModules.notDetected @@ -124,20 +122,19 @@ in libva vulkan-loader ]; - extraPackages32 = with pkgs.pkgsi686Linux; - [ - libvdpau-va-gl - vaapiVdpau - libva - vulkan-loader - ]; + extraPackages32 = with pkgs.pkgsi686Linux; [ + libvdpau-va-gl + vaapiVdpau + libva + vulkan-loader + ]; }; pulseaudio = { enable = false; support32Bit = true; }; }; - + programs.light.enable = true; fonts = { @@ -150,7 +147,14 @@ in systemPackages = [pkgs.ntfs3g]; pathsToLink = ["/share/zsh"]; persistence."${config.system.persistDir}" = { - directories = ["/etc/nixos"]; + directories = lib.flatten [ + "/etc/nixos" + ( + lib.optional + config.virtualisation.docker.enable + ["/var/lib/docker" "/var/lib/containers"] + ) + ]; files = ["/etc/machine-id"]; }; }; @@ -170,6 +174,7 @@ in virtualisation = { waydroid.enable = false; podman.enable = false; + docker.enable = true; libvirtd.enable = false; }; diff --git a/modules/base/hm-system-defaults.nix b/modules/base/hm-system-defaults.nix index 272b0d8..f85b4c4 100644 --- a/modules/base/hm-system-defaults.nix +++ b/modules/base/hm-system-defaults.nix @@ -10,6 +10,7 @@ home.sessionVariables = {inherit (config.environment.sessionVariables) NIX_PATH;}; xdg.configFile."nix/registry.json".text = config.environment.etc."nix/registry.json".text; xdg.configFile."nix/nix.conf".source = config.environment.etc."nix/nix.conf".source; + xdg.configFile."nix/netrc".source = config.environment.etc."nix/netrc".source; } ]; home-manager.extraSpecialArgs = {inherit inputs;}; diff --git a/modules/base/nix.nix b/modules/base/nix.nix index f7aae73..72aac6b 100644 --- a/modules/base/nix.nix +++ b/modules/base/nix.nix @@ -2,6 +2,7 @@ pkgs, lib, inputs, + config, ... }: { nix = { @@ -19,6 +20,7 @@ fallback = true extra-experimental-features = nix-command flakes builders-use-substitutes = true + netrc-file = /etc/nix/netrc ''; nixPath = ["nixpkgs=${inputs.nixpkgs}" "home-manager=${inputs.home}"]; }; @@ -28,4 +30,7 @@ trusted-users = ["root" "@wheel"]; auto-optimise-store = true; }; + environment.etc."nix/netrc".text = '' + machine private-ardanalabs.cachix.org password ${config.environment.sessionVariables.CACHIX_AUTH_TOKEN} + ''; } diff --git a/pkgs-set/overlays/helix.nix b/pkgs-set/overlays/helix.nix index 494ac99..41649e6 100644 --- a/pkgs-set/overlays/helix.nix +++ b/pkgs-set/overlays/helix.nix @@ -1,3 +1,8 @@ {inputs}: final: prev: { - helix = inputs.helix.packages.${prev.system}.default; + helix = inputs.helix.packages.${prev.system}.default.override { + includeGrammarIf = grammar: + prev.lib.any + (name: grammar.name == name) + ["toml" "rust" "nix" "protobuf" "yaml" "json" "markdown"]; + }; } diff --git a/pkgs-set/overlays/steam.nix b/pkgs-set/overlays/steam.nix index caf438b..958ef99 100644 --- a/pkgs-set/overlays/steam.nix +++ b/pkgs-set/overlays/steam.nix @@ -1,9 +1,9 @@ final: prev: { steam = prev.steam.override { extraLibraries = pkgs: with pkgs; [mimalloc pipewire vulkan-loader wayland wayland-protocols]; - extraProfile = '' - unset VK_ICD_FILENAMES - export VK_ICD_FILENAMES="/run/opengl-driver/share/vulkan/icd.d:/run/opengl-driver-32/share/vulkan/icd.d" - ''; + # extraProfile = '' + # unset VK_ICD_FILENAMES + # export VK_ICD_FILENAMES="/run/opengl-driver/share/vulkan/icd.d:/run/opengl-driver-32/share/vulkan/icd.d" + # ''; }; } diff --git a/secrets/default.nix b/secrets/default.nix index 67fea32a7cb501a5befd48f9f099ab96f725a5d7..304184baee2532d400a12528df8609150d4ff284 100644 GIT binary patch literal 642 zcmV-|0)71eM@dveQdv+`0Fw`+vJ(W2SfAB_?FoIH&`L6mUN-fGI_CJQm3w#vrgWFY zE7ry^(Yn&(*M`vv(;8MZ1!4T%i2&wgy$aGk}|I;DXoRAja^ow z;IdjNK=8dWI-iKtf)@4M@?jA(ps#!vNMQt!^s%~*Y7quWUdl-ILiv z7Z8Xp^E0~lmu(^oz;0igX{y@!PEh@GD^p8r`H9M9iS`X^u=gi%IImx&OE73~E`Ry& zJUgemJbyk)aRI`usvl)ytL>rF`u;@%-z{#HQ@$BJDoq(+_ZL%qmIw-a0-~wY{t{C( z1b={RW9NGl?tPBb>gVf}BzA_KjdqV@A)8V)731RDSqXYzE^B!vmzFe@YL)&A%wY_n z5Kd&RN24I7NoOzmM82Pkv%LYro>YUwl<8FcG=8VOrla-e+>unGX+D1Y^}95si!pxS cx7`FfB&h2`0|Y%_jbzzu=F4WQo&nU%?jssPf&c&j literal 248 zcmV6