Compare commits

..

10 commits

24 changed files with 236 additions and 339 deletions

View file

@ -8,20 +8,29 @@ My NixOS configurations, using flakes.
- Text editor: [neovim](https://github.com/neovim/neovim)
- Shell: [fish](https://github.com/fish-shell/fish-shell)
- Colors: [Catppuccin](https://github.com/catppuccin/catppuccin)
- Font: [Intel One Mono](github.com/intel/intel-one-mono)
- Font: [Intel One Mono](https://github.com/intel/intel-one-mono)
Additionally using a lot of other software you can find in the configuration files.
# 🛠️ Structure
| Name | Description |
| ------------------- | ------------------------------------------------- |
| ------------------- | -------------------------- |
| [home](home/) | Home manager configuration |
| [hosts](hosts/) | Host-specific (entry-points of the configuration) |
| [hosts](hosts/) | Host-specific |
| [lib](lib/) | Helper functions |
| [modules](modules/) | NixOS modules |
| [system](system/) | NixOS configuration |
My configuration is structured based on the following principles:
1. Hosts should be the main entry points and outputs.
2. Abstractions should be avoided as much as possible.
The bulk of the configuration can be found either in [home](home/) or [system](system/), which declares most of my programs, with some extra Nix code in [lib](lib/) and custom [modules](modules/), mostly for convenience and to provide a way to globally set styles and themes for now.
My hosts can then pick and choose the programs and configurations that they need from the other directories. If the need arises for a more modular setup for a specific piece of software (ie. having different flavors of Firefox per host), I will write a custom module for it. This helps to avoid unnecessarily abstracting my configuration, as I don't find it necessary for the most part, and I would also like it to remain as simple as possible.
# 👥 Credits
People / repositories I have copied / learned from:
@ -29,4 +38,4 @@ People / repositories I have copied / learned from:
- [fufexan/dotfiles](https://github.com/fufexan/dotfiles) for the configuration structure
- [jacekpoz/nixos](https://git.jacekpoz.pl/poz/niksos) for learning how NixOS modules work
Some bits have also been borrowed from within the configuration, and credit has been given when its due.
Some bits have also been borrowed from within the configuration, and credit has been given where its due.

View file

@ -39,28 +39,6 @@
"type": "github"
}
},
"chaotic": {
"inputs": {
"flake-schemas": "flake-schemas",
"home-manager": "home-manager",
"jovian": "jovian",
"nixpkgs": "nixpkgs_3"
},
"locked": {
"lastModified": 1729510449,
"narHash": "sha256-/EwjBMYBZ3/2ROT+4M/6tLomgJEgZBpKosWhqtYZkDI=",
"owner": "chaotic-cx",
"repo": "nyx",
"rev": "4e03e8d762623ca925c604800aa18f109cd3bd97",
"type": "github"
},
"original": {
"owner": "chaotic-cx",
"ref": "nyxpkgs-unstable",
"repo": "nyx",
"type": "github"
}
},
"crane": {
"inputs": {
"nixpkgs": [
@ -156,26 +134,6 @@
}
},
"flake-parts_2": {
"inputs": {
"nixpkgs-lib": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1727826117,
"narHash": "sha256-K5ZLCyfO/Zj9mPFldf3iwS6oZStJcU4tSpiXTMYaaL0=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "3d04084d54bedc3d6b8b736c70ef449225c361b1",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "flake-parts",
"type": "github"
}
},
"flake-parts_3": {
"inputs": {
"nixpkgs-lib": [
"lanzaboote",
@ -196,7 +154,7 @@
"type": "github"
}
},
"flake-parts_4": {
"flake-parts_3": {
"inputs": {
"nixpkgs-lib": "nixpkgs-lib_2"
},
@ -214,7 +172,7 @@
"type": "github"
}
},
"flake-parts_5": {
"flake-parts_4": {
"inputs": {
"nixpkgs-lib": "nixpkgs-lib_3"
},
@ -232,20 +190,6 @@
"type": "github"
}
},
"flake-schemas": {
"locked": {
"lastModified": 1721999734,
"narHash": "sha256-G5CxYeJVm4lcEtaO87LKzOsVnWeTcHGKbKxNamNWgOw=",
"rev": "0a5c42297d870156d9c57d8f99e476b738dcd982",
"revCount": 75,
"type": "tarball",
"url": "https://api.flakehub.com/f/pinned/DeterminateSystems/flake-schemas/0.1.5/0190ef2f-61e0-794b-ba14-e82f225e55e6/source.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://flakehub.com/f/DeterminateSystems/flake-schemas/%3D0.1.5.tar.gz"
}
},
"flake-utils": {
"locked": {
"lastModified": 1629284811,
@ -262,26 +206,6 @@
}
},
"flake-utils_2": {
"inputs": {
"systems": [
"systems"
]
},
"locked": {
"lastModified": 1726560853,
"narHash": "sha256-X6rJYSESBVr3hBoH0WbKE5KvhPU5bloyZ2L4K60/fPQ=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "c1dfcf08411b08f6b8615f7d8971a2bfa81d5e8a",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"flake-utils_3": {
"inputs": {
"systems": "systems_2"
},
@ -299,7 +223,7 @@
"type": "github"
}
},
"flake-utils_4": {
"flake-utils_3": {
"inputs": {
"systems": "systems_3"
},
@ -317,7 +241,7 @@
"type": "github"
}
},
"flake-utils_5": {
"flake-utils_4": {
"inputs": {
"systems": "systems_6"
},
@ -392,27 +316,6 @@
}
},
"home-manager": {
"inputs": {
"nixpkgs": [
"chaotic",
"nixpkgs"
]
},
"locked": {
"lastModified": 1729414726,
"narHash": "sha256-Dtmm1OU8Ymiy9hVWn/a2B8DhRYo9Eoyx9veERdOBR4o=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "fe56302339bb28e3471632379d733547caec8103",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "home-manager",
"type": "github"
}
},
"home-manager_2": {
"inputs": {
"nixpkgs": [
"nixpkgs"
@ -432,34 +335,12 @@
"type": "github"
}
},
"jovian": {
"inputs": {
"nix-github-actions": "nix-github-actions",
"nixpkgs": [
"chaotic",
"nixpkgs"
]
},
"locked": {
"lastModified": 1729177642,
"narHash": "sha256-DdKal+ZhB9QD/tnEwFg4cZ4j4YnrkvSljBxnyG+3eE0=",
"owner": "Jovian-Experiments",
"repo": "Jovian-NixOS",
"rev": "bb69165ff372ddbd3228a03513922acd783040e8",
"type": "github"
},
"original": {
"owner": "Jovian-Experiments",
"repo": "Jovian-NixOS",
"type": "github"
}
},
"lanzaboote": {
"inputs": {
"crane": "crane",
"flake-compat": "flake-compat_2",
"flake-parts": "flake-parts_3",
"flake-utils": "flake-utils_3",
"flake-parts": "flake-parts_2",
"flake-utils": "flake-utils_2",
"nixpkgs": [
"nixpkgs"
],
@ -563,10 +444,10 @@
},
"niri": {
"inputs": {
"flake-parts": "flake-parts_4",
"flake-parts": "flake-parts_3",
"niri-stable": "niri-stable",
"niri-unstable": "niri-unstable",
"nixpkgs": "nixpkgs_4",
"nixpkgs": "nixpkgs_3",
"nixpkgs-stable": "nixpkgs-stable_2",
"xwayland-satellite-stable": "xwayland-satellite-stable",
"xwayland-satellite-unstable": "xwayland-satellite-unstable"
@ -618,26 +499,23 @@
"type": "github"
}
},
"nix-github-actions": {
"nix-index-db": {
"inputs": {
"nixpkgs": [
"chaotic",
"jovian",
"nixpkgs"
]
},
"locked": {
"lastModified": 1690328911,
"narHash": "sha256-fxtExYk+aGf2YbjeWQ8JY9/n9dwuEt+ma1eUFzF8Jeo=",
"owner": "zhaofengli",
"repo": "nix-github-actions",
"rev": "96df4a39c52f53cb7098b923224d8ce941b64747",
"lastModified": 1729394935,
"narHash": "sha256-2ntUG+NJKdfhlrh/tF+jOU0fOesO7lm5ZZVSYitsvH8=",
"owner": "nix-community",
"repo": "nix-index-database",
"rev": "04f8a11f247ba00263b060fbcdc95484fd046104",
"type": "github"
},
"original": {
"owner": "zhaofengli",
"ref": "matrix-name",
"repo": "nix-github-actions",
"owner": "nix-community",
"repo": "nix-index-database",
"type": "github"
}
},
@ -789,22 +667,6 @@
}
},
"nixpkgs_5": {
"locked": {
"lastModified": 1729256560,
"narHash": "sha256-/uilDXvCIEs3C9l73JTACm4quuHUsIHcns1c+cHUJwA=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "4c2fcb090b1f3e5b47eaa7bd33913b574a11e0a0",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_6": {
"locked": {
"lastModified": 1726871744,
"narHash": "sha256-V5LpfdHyQkUF7RfOaDPrZDP+oqz88lTJrMT1+stXNwo=",
@ -820,7 +682,7 @@
"type": "github"
}
},
"nixpkgs_7": {
"nixpkgs_6": {
"locked": {
"lastModified": 1656753965,
"narHash": "sha256-BCrB3l0qpJokOnIVc3g2lHiGhnjUi0MoXiw6t1o8H1E=",
@ -836,7 +698,7 @@
"type": "github"
}
},
"nixpkgs_8": {
"nixpkgs_7": {
"locked": {
"lastModified": 1726871744,
"narHash": "sha256-V5LpfdHyQkUF7RfOaDPrZDP+oqz88lTJrMT1+stXNwo=",
@ -870,11 +732,11 @@
},
"nvf": {
"inputs": {
"flake-parts": "flake-parts_5",
"flake-utils": "flake-utils_4",
"flake-parts": "flake-parts_4",
"flake-utils": "flake-utils_3",
"mnw": "mnw",
"nil": "nil",
"nixpkgs": "nixpkgs_6",
"nixpkgs": "nixpkgs_5",
"nmd": "nmd",
"plugin-alpha-nvim": "plugin-alpha-nvim",
"plugin-bufdelete-nvim": "plugin-bufdelete-nvim",
@ -2664,7 +2526,7 @@
"rnix-lsp": {
"inputs": {
"naersk": "naersk",
"nixpkgs": "nixpkgs_7",
"nixpkgs": "nixpkgs_6",
"utils": "utils"
},
"locked": {
@ -2685,15 +2547,13 @@
"inputs": {
"ags": "ags",
"basix": "basix",
"chaotic": "chaotic",
"firefox-addons": "firefox-addons",
"flake-parts": "flake-parts_2",
"flake-utils": "flake-utils_2",
"home-manager": "home-manager_2",
"home-manager": "home-manager",
"lanzaboote": "lanzaboote",
"niri": "niri",
"nix-index-db": "nix-index-db",
"nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs_5",
"nixpkgs": "nixpkgs_4",
"nvf": "nvf",
"plasma-manager": "plasma-manager",
"systems": "systems_5",
@ -2866,7 +2726,7 @@
},
"treefmt-nix": {
"inputs": {
"nixpkgs": "nixpkgs_8"
"nixpkgs": "nixpkgs_7"
},
"locked": {
"lastModified": 1729242555,
@ -2899,7 +2759,7 @@
},
"wezterm": {
"inputs": {
"flake-utils": "flake-utils_5",
"flake-utils": "flake-utils_4",
"freetype2": "freetype2",
"harfbuzz": "harfbuzz",
"libpng": "libpng",

View file

@ -1,85 +1,64 @@
{
description = "nezia's nixos configuration";
outputs = inputs:
inputs.flake-parts.lib.mkFlake {inherit inputs;} {
systems = ["x86_64-linux"];
imports = [
./hosts
./modules
];
perSystem = {pkgs, ...}: {
devShells.default = pkgs.mkShell {
outputs = {
self,
nixpkgs,
systems,
treefmt-nix,
...
} @ inputs: let
eachSystem = f: nixpkgs.lib.genAttrs (import systems) (system: f nixpkgs.legacyPackages.${system});
treefmtEval = eachSystem (pkgs: treefmt-nix.lib.evalModule pkgs ./treefmt.nix);
in {
devShells = eachSystem (pkgs: {
default = pkgs.mkShell {
packages = [
pkgs.alejandra
pkgs.git
];
};
formatter = pkgs.alejandra;
});
formatter = eachSystem (pkgs: treefmtEval.${pkgs.system}.config.build.wrapper);
nixosModules = import ./modules;
nixosConfigurations = import ./hosts {inherit self inputs;};
};
};
inputs = {
# global, so they can be `.follow`ed
systems.url = "github:nix-systems/default-linux";
flake-utils = {
url = "github:numtide/flake-utils";
inputs.systems.follows = "systems";
};
flake-parts = {
url = "github:hercules-ci/flake-parts";
inputs.nixpkgs-lib.follows = "nixpkgs";
};
# nix related
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
chaotic.url = "github:chaotic-cx/nyx/nyxpkgs-unstable";
firefox-addons = {
url = "gitlab:rycee/nur-expressions?dir=pkgs/firefox-addons";
systems.url = "github:nix-systems/default-linux";
nixos-hardware.url = "github:NixOS/nixos-hardware";
lanzaboote = {
url = "github:nix-community/lanzaboote/v0.4.1";
inputs.nixpkgs.follows = "nixpkgs";
};
home-manager = {
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
wezterm = {
url = "github:wez/wezterm/main?dir=nix";
nix-index-db = {
url = "github:nix-community/nix-index-database";
inputs.nixpkgs.follows = "nixpkgs";
};
nvf = {
url = "github:notashelf/nvf";
};
# other
ags.url = "github:Aylur/ags";
basix.url = "github:notashelf/basix";
firefox-addons = {
url = "gitlab:rycee/nur-expressions?dir=pkgs/firefox-addons";
inputs.nixpkgs.follows = "nixpkgs";
};
niri = {url = "github:sodiboo/niri-flake";};
nvf.url = "github:notashelf/nvf";
plasma-manager = {
url = "github:nix-community/plasma-manager";
inputs.nixpkgs.follows = "nixpkgs";
inputs.home-manager.follows = "home-manager";
};
ags.url = "github:Aylur/ags";
niri = {
url = "github:sodiboo/niri-flake";
};
lanzaboote = {
url = "github:nix-community/lanzaboote/v0.4.1";
# Optional but recommended to limit the size of your system closure.
treefmt-nix.url = "github:numtide/treefmt-nix";
wezterm = {
url = "github:wez/wezterm/main?dir=nix";
inputs.nixpkgs.follows = "nixpkgs";
};
treefmt-nix.url = "github:numtide/treefmt-nix";
nixos-hardware.url = "github:NixOS/nixos-hardware";
};
}

View file

@ -1,5 +1,4 @@
{
lib,
inputs,
pkgs,
...
@ -61,7 +60,6 @@ in {
profiles = {
nezia = {
settings = {
"browser.urlbar.suggest.searches" = true;
"browser.search.suggest.enabled" = true;
"ui.key.menuAccessKeyFocuses" = false;
};
@ -73,48 +71,12 @@ in {
stylus
ublock-origin
violentmonkey
idontcareaboutcookies
];
# https://git.jacekpoz.pl/poz/niksos/src/commit/a48647a1c5bc6877a1100a65f4dc169b2fc11ed7/hosts/hape/firefox.nix
search = {
default = "SearxNG";
engines = {
"Nix Packages" = {
urls = [
{
template = "https://search.nixos.org/packages";
params = [
{
name = "type";
value = "packages";
}
{
name = "query";
value = "{searchTerms}";
}
];
}
];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = ["@np"];
};
"NixOS Wiki" = {
urls = [{template = "https://wiki.nixos.org/w/index.php?search={searchTerms}";}];
iconUpdateURL = "https://wiki.nixos.org/favicon.ico";
updateInterval = 24 * 60 * 60 * 1000; # every day
definedAliases = ["@nw"];
};
"Home Manager Options" = {
urls = [{template = "https://home-manager-options.extranix.com/?release=master&query={searchTerms}";}];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = ["@hm"];
};
"Arch Wiki" = {
urls = [{template = "https://wiki.archlinux.org/index.php?search={searchTerms}";}];
icon = "https://archlinux.org/favicon.ico";
definedAliases = ["@aw"];
};
"SearxNG" = {
urls = [
{
@ -139,13 +101,56 @@ in {
"type" = "application/x-suggestions+json";
}
];
definedAliases = ["@sx"];
iconUpdateURL = "https://searx.tiekoetter.com/favicon.ico";
updateInterval = 24 * 60 * 60 * 1000;
definedAliases = ["@s"];
};
"Nix Packages" = {
urls = [
{
template = "https://search.nixos.org/packages";
params = [
{
name = "type";
value = "packages";
}
{
name = "query";
value = "{searchTerms}";
}
];
}
];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = ["@np"];
};
"NixOS Wiki" = {
urls = [{template = "https://wiki.nixos.org/w/index.php?search={searchTerms}";}];
iconUpdateURL = "https://wiki.nixos.org/favicon.ico";
updateInterval = 24 * 60 * 60 * 1000;
definedAliases = ["@nw"];
};
"NixOS Options" = {
urls = [{template = "https://search.nixos.org/options?channel=unstable&type=packages&query={searchTerms}";}];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = ["@no"];
};
"Noogle" = {
urls = [{template = "https://noogle.dev/q?term={searchTerms}";}];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = ["@ng"];
};
"Home Manager" = {
urls = [{template = "https://home-manager-options.extranix.com/?release=master&query={searchTerms}";}];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = ["@hm"];
};
"Google".metaData.alias = "@g"; # builtin engines only support specifying one additional alias
};
};
# https://github.com/oddlama/nix-config/blob/main/users/myuser/graphical/firefox.nix#L53-L57
extraConfig = builtins.concatStringsSep "\n" [
(builtins.readFile "${betterfox}/user.js")
(builtins.readFile "${betterfox}/Securefox.js")
(builtins.readFile "${betterfox}/Fastfox.js")
(builtins.readFile "${betterfox}/Peskyfox.js")

View file

@ -1,6 +1,6 @@
{
inputs,
nixosConfig,
osConfig,
lib,
pkgs,
...
@ -15,7 +15,7 @@
font = "monospace:size=14";
};
colors = let
inherit (inputs.basix.schemeData.base16.${nixosConfig.style.scheme}) palette;
inherit (inputs.basix.schemeData.base16.${osConfig.theme.scheme}) palette;
in {
background = "${palette.base00}ff";
text = "${palette.base05}ff";

View file

@ -6,10 +6,10 @@
lib,
...
}: let
isDark = inputs.basix.schemeData.base16.${osConfig.style.scheme}.variant == "dark";
isDark = inputs.basix.schemeData.base16.${osConfig.theme.scheme}.variant == "dark";
in {
home.pointerCursor = {
inherit (osConfig.style.cursorTheme) name package size;
inherit (osConfig.theme.cursorTheme) name package size;
gtk.enable = true;
x11.enable = true;
};
@ -35,11 +35,11 @@ in {
gtk2.configLocation = "${config.xdg.configHome}/gtk-2.0/gtkrc";
iconTheme = {
inherit (osConfig.style.gtk.iconTheme) name package;
inherit (osConfig.theme.gtk.iconTheme) name package;
};
theme = lib.mkIf (!osConfig.services.xserver.desktopManager.gnome.enable) {
inherit (osConfig.style.gtk.theme) name package;
inherit (osConfig.theme.gtk.theme) name package;
};
};
dconf.settings = {

View file

@ -6,7 +6,7 @@
osConfig,
...
}: let
colors = inputs.basix.schemeData.base16.${osConfig.style.scheme}.palette;
colors = inputs.basix.schemeData.base16.${osConfig.theme.scheme}.palette;
in {
imports = [./binds.nix];

View file

@ -2,7 +2,7 @@
{
pkgs,
lib,
nixosConfig,
osConfig,
...
}: {
systemd.user.services.swaybg = {
@ -11,7 +11,7 @@
PartOf = ["graphical-session.target"];
};
Service = {
ExecStart = "${lib.getExe pkgs.swaybg} -i ${nixosConfig.style.wallpaper} -m fill";
ExecStart = "${lib.getExe pkgs.swaybg} -i ${osConfig.theme.wallpaper} -m fill";
Restart = "on-failure";
};
Install.WantedBy = ["graphical-session.target"];

View file

@ -1,10 +1,10 @@
{
inputs,
pkgs,
nixosConfig,
osConfig,
...
}: let
inherit (inputs.basix.schemeData.base16.${nixosConfig.style.scheme}) palette;
inherit (inputs.basix.schemeData.base16.${osConfig.theme.scheme}) palette;
in {
# requires `security.pam.services.swaylock = { };` at the system level or else
# unlock will not work.

View file

@ -1,6 +1,6 @@
{
inputs,
nixosConfig,
osConfig,
config,
lib,
...
@ -14,7 +14,7 @@
shell = "${lib.getExe config.programs.fish.package}";
};
colors = let
schemeData = inputs.basix.schemeData.base16.${nixosConfig.style.scheme};
schemeData = inputs.basix.schemeData.base16.${osConfig.theme.scheme};
in {
background = schemeData.palette.base00;
foreground = schemeData.palette.base05;

View file

@ -5,6 +5,7 @@
./tmux.nix
./direnv.nix
./zellij.nix
./nix-index.nix
];
home.packages = with pkgs; [

View file

@ -0,0 +1,11 @@
{inputs, ...}: {
imports = [inputs.nix-index-db.hmModules.nix-index];
programs = {
nix-index = {
enable = true;
symlinkToCacheHome = true; # needed for comma
};
command-not-found.enable = false;
nix-index-database.comma.enable = true;
};
}

25
hosts/README.md Normal file
View file

@ -0,0 +1,25 @@
# 💻 Hosts
This directory contains the entry points for different NixOS system configurations. Each host represents a complete system configuration, combining NixOS system settings and Home Manager configurations.
## Components
### default.nix
The `default.nix` file in each host directory serves as the main entry point for the system configuration. It:
- Sets up NixOS configurations
- Sets up Home Manager configurations
- References host-specific module declarations
### modules/
The `modules/` directory contains host-specific declarations for custom modules that are defined in the flake's `nixosModules` output. This so far only includes global theme / style related declarations.
## Adding a New Host
1. Create a new directory for the host
2. Add a `hardware-configuration.nix` generated with `nixos-generate-config`
3. Add a `default.nix` that imports the desired configurations
4. Create host-specific module declarations in the `modules/` subdirectory to customize the global modules as needed
5. Reference the new host in `hosts/default.nix`

View file

@ -2,48 +2,30 @@
self,
inputs,
...
}: {
flake.nixosConfigurations = let
}: let
inherit (inputs.nixpkgs.lib) nixosSystem;
specialArgs = {
inherit inputs self;
};
in {
in {
vamos = nixosSystem {
system = "x86_64-linux";
inherit specialArgs;
modules = [
./vamos
self.nixosModules.style
({pkgs, ...}: {
style = let
wallpaper = pkgs.fetchurl {
url = "https://raw.githubusercontent.com/NixOS/nixos-artwork/e0cf0eb237dc5baba86661a3572b20a6183c1876/wallpapers/nix-wallpaper-nineish-catppuccin-frappe.png?raw=true";
hash = "sha256-/HAtpGwLxjNfJvX5/4YZfM8jPNStaM3gisK8+ImRmQ4=";
};
in {
gtk.enable = true;
inherit wallpaper;
};
})
self.nixosModules.theme
inputs.nixos-hardware.nixosModules.framework-13-7040-amd
];
};
solaire = nixosSystem {
system = "x86_64-linux";
inherit specialArgs;
modules = [
./solaire
self.nixosModules.style
{
style = {
gtk.enable = false;
wallpaper = ../wallpapers/lucy-edgerunners-wallpaper.jpg;
};
}
self.nixosModules.theme
];
};
};
}

View file

@ -7,6 +7,7 @@
in {
imports = [
./hardware-configuration.nix
./modules
"${mod}"
"${mod}/hardware/uni-sync.nix"

View file

@ -0,0 +1,3 @@
{
imports = [./theme.nix];
}

View file

@ -0,0 +1,3 @@
{
theme.wallpaper = ../../wallpapers/lucy-edgerunners-wallpaper.jpg;
}

View file

@ -7,6 +7,7 @@
in {
imports = [
./hardware-configuration.nix
./modules
"${mod}"
"${mod}/core/lanzaboote.nix"

View file

@ -0,0 +1,3 @@
{
imports = [./theme.nix];
}

View file

@ -0,0 +1,8 @@
{pkgs, ...}: {
theme = {
wallpaper = pkgs.fetchurl {
url = "https://raw.githubusercontent.com/NixOS/nixos-artwork/e0cf0eb237dc5baba86661a3572b20a6183c1876/wallpapers/nix-wallpaper-nineish-catppuccin-frappe.png?raw=true";
hash = "sha256-/HAtpGwLxjNfJvX5/4YZfM8jPNStaM3gisK8+ImRmQ4=";
};
};
}

View file

@ -1,5 +1,3 @@
{
flake.nixosModules = {
style = import ./style;
};
theme = import ./theme;
}

View file

@ -7,7 +7,7 @@
inherit (lib.types) string path package;
in {
imports = [./gtk.nix];
options.style = {
options.theme = {
scheme = mkOption {
description = ''
Name of the tinted-scheming color scheme to use.
@ -22,6 +22,10 @@ in {
'';
type = path;
example = lib.literalExpression "./wallpaper.png";
default = pkgs.fetchurl {
url = "https://raw.githubusercontent.com/NixOS/nixos-artwork/e0cf0eb237dc5baba86661a3572b20a6183c1876/wallpapers/nix-wallpaper-nineish-catppuccin-frappe.png?raw=true";
hash = "sha256-/HAtpGwLxjNfJvX5/4YZfM8jPNStaM3gisK8+ImRmQ4=";
};
};
cursorTheme = {

View file

@ -8,9 +8,9 @@
inherit (lib) mkOption mkEnableOption;
inherit (lib.types) package str;
cfg = config.style.gtk;
cfg = config.theme.gtk;
in {
options.style.gtk = {
options.theme.gtk = {
enable = mkEnableOption "enable GTK theming options";
theme = {
name = mkOption {
@ -57,7 +57,7 @@ in {
${toString themePath} set by the GTK module does not exist!
To suppress this message, make sure that
`config.modules.style.gtk.theme.package` contains
`config.modules.theme.gtk.theme.package` contains
the path `${cfg.theme.name}`
'';
})

View file

@ -1,6 +1,10 @@
# TODO: maybe use flake-parts
{...}: {
# Used to find the project root
{pkgs, ...}: {
projectRootFile = "flake.nix";
programs.alejandra.enable = true;
programs = {
alejandra.enable = true;
prettier = {
enable = true;
package = pkgs.prettierd;
};
};
}