207 lines
6.5 KiB
Nix
Executable File
207 lines
6.5 KiB
Nix
Executable File
{
|
|
description = "A Flake lol";
|
|
|
|
inputs = {
|
|
nixpkgs.url = "nixpkgs/nixos-23.11";
|
|
nixpkgs-unstable.url = "nixpkgs/nixos-unstable";
|
|
home-manager = {
|
|
url = "github:nix-community/home-manager/release-23.11";
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
|
|
hyprland = {
|
|
url = "git+https://github.com/hyprwm/Hyprland?submodules=1";
|
|
# url = "github:hyprwm/Hyprland";
|
|
# inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
hyprland-plugins = {
|
|
url = "github:hyprwm/hyprland-plugins";
|
|
inputs.hyprland.follows = "hyprland";
|
|
};
|
|
# Hyprspace = {
|
|
# url = "github:KZDKM/Hyprspace";
|
|
# inputs.hyprland.follows = "hyprland";
|
|
# };
|
|
|
|
# nixvim = {
|
|
# url = "github:nix-community/nixvim/nixos-23.11";
|
|
# inputs.nixpkgs.follows = "nixpkgs";
|
|
# };
|
|
lanzaboote = {
|
|
url = "github:nix-community/lanzaboote/v0.3.0";
|
|
# inputs.nixpkgs.follows = "nixpkgs-unstable";
|
|
};
|
|
#arion = {
|
|
# url = "github:hercules-ci/arion";
|
|
# inputs.nixpkgs.follows = "nixpkgs";
|
|
#};
|
|
firefox-addons = {
|
|
url = "gitlab:rycee/nur-expressions?dir=pkgs/firefox-addons";
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
# yazi.url = "github:sxyazi/yazi";
|
|
};
|
|
|
|
outputs = { self, nixpkgs, nixpkgs-unstable, home-manager, ... }@inputs:
|
|
let
|
|
system = "x86_64-linux";
|
|
pkgs = nixpkgs.legacyPackages.${system};
|
|
pkgs-unstable = nixpkgs-unstable.legacyPackages.${system};
|
|
|
|
user = "nx2";
|
|
|
|
nvidia = rec {
|
|
enable = true;
|
|
prime = true;
|
|
# unfree = if enable then [
|
|
unfree = [
|
|
"nvidia-x11"
|
|
"nvidia-settings"
|
|
"nvidia-persistenced"
|
|
"cudatoolkit"
|
|
"cudatoolkit-11.8.0"
|
|
"cudatoolkit-12.2.2"
|
|
];
|
|
# ] else [];
|
|
};
|
|
allowed = {
|
|
unfree-packages = [
|
|
"spotify"
|
|
"cudatoolkit-12.2.2"
|
|
"discord"
|
|
"obsidian"
|
|
"zoom-us"
|
|
"zoom"
|
|
] ++ nvidia.unfree;
|
|
|
|
inecure-packages = [
|
|
"electron-25.9.0"
|
|
];
|
|
};
|
|
|
|
secrets = import ./secrets/passwords-and-certificates.nix;
|
|
|
|
rice = rec {
|
|
lib = import ./nxlib/ricelib.nix { lib = nixpkgs.lib; };
|
|
transparency = 0.8;
|
|
rounding = 10;
|
|
gap-size = 10;
|
|
border-width = 3;
|
|
color =
|
|
let
|
|
dark = (-0.3);
|
|
bright = (0.5);
|
|
alter-set = let f = rice.lib.alter-luminace-hex; in color-name: color-value: { base = color-value; dark = f color-value dark; bright = f color-value bright; };
|
|
alter = let f = rice.lib.alter-luminace-hex; in color-value: { base = color-value; dark = f color-value dark; bright = f color-value bright; };
|
|
ccolor = builtins.mapAttrs alter-set {
|
|
black = "#000022"; # "#111111" "#001100";
|
|
white = "#ddddff"; # "#dddddd" "#66dd66";
|
|
blue = "#4422ff"; # "#3333dd" "#003300";
|
|
cyan = "#11dddd"; # "#11dddd" "#00dd55";
|
|
green = "#11dd99"; # "#11dd11" "#11dd11";
|
|
magenta = "#6622dd"; # "#dd11dd" "#005500";
|
|
red = "#dd1166"; # "#dd1111" "#00aa00";
|
|
yellow = "#dd6611"; # "#dddd11" "#ffff00";
|
|
};
|
|
xcolor = with ccolor; {
|
|
background = black.dark;
|
|
foreground = white.base;
|
|
border = cyan.base;
|
|
border2 = blue.base;
|
|
accent = blue;
|
|
secondary = cyan;
|
|
tertiary = magenta;
|
|
special = yellow;
|
|
weird = green;
|
|
positive = alter "#00dd00";
|
|
negative = alter "#dd0000";
|
|
};
|
|
in ccolor // xcolor;
|
|
font = {
|
|
code = {
|
|
name = "JetBrainsMono-NF";
|
|
name2 = "JetBrainsMono Nerd Font";
|
|
package = (pkgs.nerdfonts.override { fonts = [ "JetBrainsMono" ]; });
|
|
# name = "CascadiaCove-NF";
|
|
# package = (pkgs.nerdfonts.override { fonts = [ "CascadiaCode" ]; });
|
|
};
|
|
base = {
|
|
name = "Atkinson Hyperlegible";
|
|
package = pkgs.atkinson-hyperlegible;
|
|
};
|
|
};
|
|
};
|
|
in
|
|
{
|
|
nixosConfigurations = {
|
|
NxXPS =
|
|
let
|
|
host = "NxXPS";
|
|
in
|
|
nixpkgs.lib.nixosSystem {
|
|
inherit system;
|
|
modules = [ ./configuration.nix ];
|
|
specialArgs = { inherit inputs user host pkgs-unstable allowed secrets rice nvidia; };
|
|
};
|
|
NxNORTH = let host = "NxNORTH"; in nixpkgs.lib.nixosSystem {
|
|
inherit system;
|
|
modules = [ ./configuration.nix ];
|
|
specialArgs = { inherit inputs user host pkgs-unstable allowed secrets rice nvidia; };
|
|
};
|
|
NxACE =
|
|
let
|
|
host = "NxACE";
|
|
nvidia.enable = false;
|
|
in
|
|
nixpkgs.lib.nixosSystem {
|
|
inherit system;
|
|
modules = [ ./configuration.nix ];
|
|
specialArgs = { inherit inputs user host pkgs-unstable allowed secrets rice nvidia; };
|
|
};
|
|
};
|
|
|
|
homeConfigurations = {
|
|
"${user}@NxXPS" = let host = "NxXPS"; in home-manager.lib.homeManagerConfiguration {
|
|
inherit pkgs;
|
|
modules = [
|
|
./home.nix
|
|
];
|
|
extraSpecialArgs = { inherit inputs system user host allowed secrets pkgs-unstable rice nvidia; };
|
|
};
|
|
"${user}@NxNORTH" = let host = "NxNORTH"; in home-manager.lib.homeManagerConfiguration {
|
|
inherit pkgs;
|
|
modules = [
|
|
./home.nix
|
|
];
|
|
extraSpecialArgs = { inherit inputs system user host allowed secrets pkgs-unstable rice nvidia; };
|
|
};
|
|
|
|
"${user}@NxACE" =
|
|
let
|
|
host = "NxACE";
|
|
nvidia.enable = false;
|
|
in
|
|
home-manager.lib.homeManagerConfiguration {
|
|
inherit pkgs;
|
|
modules = [
|
|
./home.nix
|
|
];
|
|
extraSpecialArgs = { inherit inputs system user host allowed secrets pkgs-unstable rice nvidia; };
|
|
};
|
|
"tv@NxACE" =
|
|
let
|
|
host = "NxACE";
|
|
user = "tv";
|
|
nvidia.enable = pkgs.kib.mkForce false;
|
|
in
|
|
home-manager.lib.homeManagerConfiguration {
|
|
inherit pkgs;
|
|
modules = [
|
|
./home.nix
|
|
];
|
|
extraSpecialArgs = { inherit inputs system user host allowed secrets pkgs-unstable rice nvidia; };
|
|
};
|
|
};
|
|
};
|
|
}
|