mirror of
https://github.com/youwen5/liminalOS.git
synced 2025-06-20 05:59:51 -07:00
refactor: do not depend on inputs for modules
This commit is contained in:
parent
dbc5fbd875
commit
8424b025f6
11 changed files with 87 additions and 39 deletions
|
@ -3,7 +3,7 @@
|
|||
# persist between generations. This is not ideal, but at least it is a better
|
||||
# situation than imperative installation
|
||||
{
|
||||
inputs,
|
||||
liminalSystemModules,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
|
@ -13,7 +13,7 @@ let
|
|||
in
|
||||
{
|
||||
imports = [
|
||||
inputs.nix-flatpak.nixosModules.nix-flatpak
|
||||
liminalSystemModules.nix-flatpak.nixosModules.nix-flatpak
|
||||
];
|
||||
|
||||
options.liminalOS.programs.flatpak = {
|
||||
|
|
|
@ -103,6 +103,9 @@ in
|
|||
)
|
||||
);
|
||||
|
||||
services.tlp.enable = lib.mkIf (cfg.formFactor == "laptop") true;
|
||||
programs.light.enable = lib.mkIf (cfg.formFactor == "laptop") true;
|
||||
|
||||
environment.variables.EDITOR = lib.mkIf (
|
||||
cfg.defaultEditor != null
|
||||
) cfg.defaultEditor.meta.mainProgram;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
inputs,
|
||||
liminalSystemModules,
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
|
@ -24,20 +24,45 @@ in
|
|||
Whether to enable plymouth and sane defaults.
|
||||
'';
|
||||
};
|
||||
wallpaper = lib.mkOption {
|
||||
type = lib.types.path;
|
||||
default = "../../../hm/modules/common/shellenv/fastfetch/nixos-logo.png";
|
||||
description = ''
|
||||
Path to wallpaper to set as background and generate system colorscehme from.
|
||||
'';
|
||||
};
|
||||
polarity = lib.mkOption {
|
||||
type = lib.types.nullOr (
|
||||
lib.types.enum [
|
||||
"light"
|
||||
"dark"
|
||||
]
|
||||
);
|
||||
default = null;
|
||||
description = ''
|
||||
Whether to force colorscheme to be generated as light or dark theme. Set to null to automatically determine.
|
||||
'';
|
||||
};
|
||||
base16Scheme = lib.mkOption {
|
||||
type = lib.types.nullOr lib.types.path;
|
||||
default = null;
|
||||
description = ''
|
||||
Base 16 colorscheme from base16-schemes to override wallpaper generated colorscheme with. Set to null to use wallpaper generated scheme.
|
||||
Example: ''${pkgs.base16-schemes}/share/themes/rose-pine.yaml
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
imports = [
|
||||
inputs.stylix.nixosModules.stylix
|
||||
liminalSystemModules.stylix.nixosModules.stylix
|
||||
];
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
stylix = {
|
||||
enable = true;
|
||||
image = "${inputs.wallpapers}/aesthetic/afterglow_city_skyline_at_night.png";
|
||||
# image = "${inputs.wallpapers}/aesthetic/red_deadly_sun.jpg";
|
||||
# image = "${inputs.wallpapers}/aesthetic/afterglow_sand_dunes.jpg";
|
||||
base16Scheme = "${pkgs.base16-schemes}/share/themes/rose-pine.yaml";
|
||||
polarity = "dark";
|
||||
image = lib.mkIf (cfg.wallpaper != null) cfg.wallpaper;
|
||||
base16Scheme = lib.mkIf (cfg.base16Scheme != null) cfg.base16Scheme;
|
||||
polarity = lib.mkIf (cfg.polarity != null) cfg.polarity;
|
||||
|
||||
fonts = {
|
||||
serif = {
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
inputs,
|
||||
liminalSystemModules,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
|
@ -9,7 +9,7 @@ let
|
|||
in
|
||||
{
|
||||
imports = [
|
||||
inputs.nixos-wsl.nixosModules.default
|
||||
liminalSystemModules.nixos-wsl.nixosModules.default
|
||||
];
|
||||
|
||||
options.liminalOS.wsl = {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue