summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Fischer <martin@push-f.com>2025-03-27 08:27:56 +0100
committerMartin Fischer <martin@push-f.com>2025-03-27 19:50:24 +0100
commit5a0c9eb79b5618c4894397646788e77db90429e0 (patch)
tree11b41c1f174c8e091494733791d957b1a2fe701b
parentc5ff49ba30e7e4b472c4abe7fcf589e2e419c4fc (diff)
refactor: pass config to helpers
-rw-r--r--nixos/helpers.nix2
-rw-r--r--nixos/hosts/ev/torrent.nix2
-rw-r--r--nixos/hosts/tente/default.nix6
-rw-r--r--nixos/hosts/tente/git.nix2
-rw-r--r--nixos/hosts/tente/matrix.nix2
-rw-r--r--nixos/hosts/tente/web-personal.nix2
6 files changed, 9 insertions, 7 deletions
diff --git a/nixos/helpers.nix b/nixos/helpers.nix
index e7e1877..de00136 100644
--- a/nixos/helpers.nix
+++ b/nixos/helpers.nix
@@ -1,3 +1,5 @@
+{ config, ... }:
+
let
nixpkgs = import <nixpkgs> {};
in
diff --git a/nixos/hosts/ev/torrent.nix b/nixos/hosts/ev/torrent.nix
index 7b7cbdb..ddc4dcb 100644
--- a/nixos/hosts/ev/torrent.nix
+++ b/nixos/hosts/ev/torrent.nix
@@ -1,7 +1,7 @@
{ config, lib, pkgs, ... }:
let
- helpers = import <top/helpers.nix>;
+ helpers = import <top/helpers.nix> { inherit config; };
cfg = config.torrent;
in
{
diff --git a/nixos/hosts/tente/default.nix b/nixos/hosts/tente/default.nix
index a2bf681..b4a47f0 100644
--- a/nixos/hosts/tente/default.nix
+++ b/nixos/hosts/tente/default.nix
@@ -3,14 +3,14 @@
# your system. Help is available in the configuration.nix(5) man page, on
# https://search.nixos.org/options and in the NixOS manual (`nixos-help`).
+{ config, lib, pkgs, ... }:
+
let
domain = "push-f.com";
acmeEmail = "martin@push-f.com";
sources = import ../../npins;
- helpers = import <top/helpers.nix>;
+ helpers = import <top/helpers.nix> { inherit config; };
in
-{ config, lib, pkgs, ... }:
-
{
imports = [
./hardware-configuration.nix
diff --git a/nixos/hosts/tente/git.nix b/nixos/hosts/tente/git.nix
index 912abab..ee10a43 100644
--- a/nixos/hosts/tente/git.nix
+++ b/nixos/hosts/tente/git.nix
@@ -2,7 +2,7 @@
let
cfg = config.git;
- helpers = import <top/helpers.nix>;
+ helpers = import <top/helpers.nix> { inherit config; };
in
{
options.git = {
diff --git a/nixos/hosts/tente/matrix.nix b/nixos/hosts/tente/matrix.nix
index f77274a..3dc5ad0 100644
--- a/nixos/hosts/tente/matrix.nix
+++ b/nixos/hosts/tente/matrix.nix
@@ -2,7 +2,7 @@
let
cfg = config.matrix;
- helpers = import <top/helpers.nix>;
+ helpers = import <top/helpers.nix> { inherit config; };
in
{
options.matrix = {
diff --git a/nixos/hosts/tente/web-personal.nix b/nixos/hosts/tente/web-personal.nix
index 039dec2..109a87d 100644
--- a/nixos/hosts/tente/web-personal.nix
+++ b/nixos/hosts/tente/web-personal.nix
@@ -2,7 +2,7 @@
let
cfg = config.web-personal;
- helpers = import <top/helpers.nix>;
+ helpers = import <top/helpers.nix> { inherit config; };
in
{
options.web-personal = {