fix module

This commit is contained in:
2026-03-26 23:31:01 +01:00
parent fb4142d95d
commit 815401f900
3 changed files with 7 additions and 11 deletions

10
flake.lock generated
View File

@@ -30,8 +30,8 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1774539899, "lastModified": 1774564167,
"narHash": "sha256-LuIiEKPwQYQJF6u/vBLBpo5ZIXH0Isgpci5zWwlQns4=", "narHash": "sha256-sdxUQJAc5t5hbQbG0SZ4B3YehTtNiRUqDNzvO/KakZk=",
"path": "/home/love/dotfiles", "path": "/home/love/dotfiles",
"type": "path" "type": "path"
}, },
@@ -47,11 +47,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1774550169, "lastModified": 1774561634,
"narHash": "sha256-cLcm8jXyhEDRHTCN1fym6+5L6Z264kj2QBpL+/yT3WI=", "narHash": "sha256-3q1xsREjqdVIIwQQDZQ9y0YdBzP8gAxdwKoKnZSzJtU=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "7622882af88598b882436416bd74154826fcf742", "rev": "7c046c63ac3b467c1d589b99d531da5b6520825a",
"type": "github" "type": "github"
}, },
"original": { "original": {

View File

@@ -30,7 +30,7 @@ in
../../modules/bin-bash-wrapper.nix ../../modules/bin-bash-wrapper.nix
]; ];
config.my.binBashWrapper.enable = true; my.binBashWrapper.enable = true;
networking.hostName = hostName; networking.hostName = hostName;
networking.hostId = "ff0b8826"; networking.hostId = "ff0b8826";

View File

@@ -4,18 +4,14 @@
pkgs, pkgs,
... ...
}: }:
let let
cfg = config.my.binBashWrapper; cfg = config.my.binBashWrapper;
bashWrapper = pkgs.writeShellScriptBin "bash" '' bashWrapper = pkgs.writeShellScriptBin "bash" ''
exec /usr/bin/env bash "$@" exec /usr/bin/env bash "$@"
''; '';
in in
{ {
cfg = { options.my.binBashWrapper.enable = lib.mkEnableOption "create a /bin/bash wrapper";
enable = lib.mkEnableOption "create a /bin/bash wrapper";
};
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
systemd.tmpfiles.rules = [ systemd.tmpfiles.rules = [