wtf is happening

This commit is contained in:
= 2024-03-12 01:43:35 -05:00
parent 91e0976cda
commit 16da7ed48b
9 changed files with 58 additions and 21 deletions

View file

@ -1,4 +1,4 @@
{ config, lib, pkgs, settings, ylib, ragenixPkg, ... }:
{ config, lib, pkgs, settings, ylib, ... } @ args:
let
home-manager = builtins.fetchTarball {
url = "https://github.com/nix-community/home-manager/archive/release-23.11.tar.gz";
@ -14,6 +14,7 @@ in
(/${settings.systemsDir}/${settings.system.hostname}/hardware-configuration.nix)
# home manager import
(import "${home-manager}/nixos")
# ./ragenix.nix
];
# Enable flakes
@ -23,7 +24,7 @@ in
security.polkit.enable = true;
home-manager.useUserPackages = true;
home-manager.useGlobalPkgs = true;
home-manager.extraSpecialArgs = { inherit settings; inherit ylib; };
home-manager.extraSpecialArgs = args;
# ==========
# Common
@ -61,9 +62,6 @@ in
git
fzf
ripgrep
# nix secrets
ragenixPkg
];
environment.shellAliases = {

View file

@ -0,0 +1,23 @@
# TODO check out the by host way this person does: https://github.com/hlissner/dotfiles/blob/089f1a9da9018df9e5fc200c2d7bef70f4546026/modules/agenix.nix
{ settings, lib, inputs, ... }:
let
secretsDir = "${settings.secretsDir}";
secretsFile = "${secretsDir}/secrets.nix";
in
{
# imports = [ inputs.ragenix.nixosModules.age ];
environment.systemPackages = [ inputs.ragenix.defaultPackage.${settings.system.architecture} ];
# age = {
# secrets =
# if pathExists secretsFile
# then
# mapAttrs'
# (n: _: nameValuePair (removeSuffix ".age" n) {
# file = "${secretsDir}/${n}";
# owner = mkDefault settings.user.username; # TODO and root? or does that matter...
# })
# (import secretsFile)
# else { };
# };
}