diff --git a/shared/home/default.nix b/shared/home/default.nix index 59b18ec..0111b7e 100644 --- a/shared/home/default.nix +++ b/shared/home/default.nix @@ -7,7 +7,10 @@ ./git.nix ./nix.nix ./programs.nix + ./theme.nix ./gui ]; + config.theme = import ../../themes/lean.nix; + } \ No newline at end of file diff --git a/shared/home/theme.nix b/shared/home/theme.nix new file mode 100644 index 0000000..c348afc --- /dev/null +++ b/shared/home/theme.nix @@ -0,0 +1,61 @@ +{ lib, ... }: + +with lib; +with types; + +let colorOpt = mkOption { + type = submodule { + options = { + basic = mkOption { type = str; }; + major = mkOption { type = str; }; + minor = mkOption { type = str; }; + }; + }; + }; + +in { + + options.theme = mkOption { + type = submodule { + options = { + background = colorOpt; + foreground = colorOpt; + + failure = mkOption { type = str; }; + success = mkOption { type = str; }; + warning = mkOption { type = str; }; + + accent = mkOption { + type = submodule { + options = { + primary = colorOpt; + secondary = colorOpt; + tertiary = colorOpt; + ordered = listToAttrs + (genList (n: { name = "${n}"; value = colorOpt; }) 8); + }; + }; + }; + + colors = mkOption { + description = '' + Colors by their name. + ''; + type = submodule { + options = { + red = colorOpt; + green = colorOpt; + blue = colorOpt; + cyan = colorOpt; + purple = colorOpt; + pink = colorOpt; + yellow = colorOpt; + orange = colorOpt; + }; + }; + }; + }; + }; + }; + +} \ No newline at end of file diff --git a/system/dev-lt-63/term.nix b/system/dev-lt-63/term.nix new file mode 100644 index 0000000..511992a --- /dev/null +++ b/system/dev-lt-63/term.nix @@ -0,0 +1,21 @@ +{ pkgs, config, ... }: + +let theme = config.theme; in { + + programs.kitty = { + enable = true; + + settings = { + term = "xterm"; + enable_audio_bell = false; + scrollback_lines = 5000000; + background = theme.background.basic; + }; + + font = { + name = "Fira Code"; + package = pkgs.fira-code; + }; + }; + +} \ No newline at end of file diff --git a/system/thor/core.nix b/system/thor/core.nix index 30085c1..a12c928 100644 --- a/system/thor/core.nix +++ b/system/thor/core.nix @@ -43,9 +43,7 @@ fsType = "vfat"; }; - #TODO - - swapDevices = [ - {device = "/dev/nixos/swap";} - ]; + swapDevices = [ + { device = "/dev/nixos/swap"; } + ]; } diff --git a/themes/lean.nix b/themes/lean.nix new file mode 100644 index 0000000..fe2a03e --- /dev/null +++ b/themes/lean.nix @@ -0,0 +1,90 @@ +rec { + + background = { + basic = "121212"; + major = "010101"; + minor = "212121"; + }; + + foreground = { + basic = "f5f5f5"; + major = "ffffff"; + minor = "ebebeb"; + }; + + failure = colors.red.major; + success = colors.green.major; + warning = colors.orange.basic; + + colors = { + + red = { + basic = "f0593e"; + major = "ff3814"; + minor = "ff8873"; + }; + + green = { + basic = "2aa61c"; + major = "39e825"; + minor = "72eb65"; + }; + + blue = { + basic = "3171eb"; + major = "4160fa"; + minor = "73a0f5"; + }; + + cyan = { + basic = "42cef5"; + major = "42f5f2"; + minor = "91e7ff"; + }; + + purple = { + basic = "9d24bf"; + major = "ca45f0"; + minor = "e28efa"; + }; + + pink = { + basic = "f25ac0"; + major = "f71eaf"; + minor = "f781d0"; + }; + + yellow = { + basic = "d3e848"; + major = "d7f700"; + minor = "dbe884"; + }; + + orange = { + basic = "f7a100"; + major = "f77700"; + minor = "f5b742"; + }; + + }; + + accent = rec { + + primary = colors.green; + secondary = colors.purple; + tertiary = colors.pink; + + ordered = with colors; { + "0" = primary; + "1" = secondary; + "2" = tertiary; + "3" = blue; + "4" = red; + "5" = orange; + "6" = yellow; + "7" = cyan; + }; + + }; + +} \ No newline at end of file