mirror of
https://github.com/buckley310/nixos-config.git
synced 2024-11-09 18:47:02 +00:00
17 lines
331 B
Nix
17 lines
331 B
Nix
|
{ config, pkgs, lib, ... }:
|
||
|
let
|
||
|
cfg = config.sconfig.user-settings;
|
||
|
in
|
||
|
{
|
||
|
options.sconfig.user-settings = lib.mkOption {
|
||
|
type = lib.types.nullOr lib.types.lines;
|
||
|
default = null;
|
||
|
};
|
||
|
|
||
|
config = lib.mkIf (cfg != null) {
|
||
|
environment.systemPackages = [
|
||
|
(pkgs.writeShellScriptBin "my-settings" cfg)
|
||
|
];
|
||
|
};
|
||
|
}
|