This repository has been archived on 2024-07-03. You can view files and clone it, but cannot push or open issues or pull requests.
home-manager/flake.nix

159 lines
4.5 KiB
Nix
Raw Normal View History

{
2024-05-11 15:42:21 +01:00
description = "Evie's home-manager configurations";
nixConfig = {
extra-substituters = ["https://nix.xenia.me.uk"];
extra-trusted-public-keys = ["nix.xenia.me.uk:tlgwOaG5KMLjQUk2YaErS8mAG69ZCr3PaHXZYi+Y5eI="];
};
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-23.11";
home-manager = {
url = "github:nix-community/home-manager/release-23.11";
inputs.nixpkgs.follows = "nixpkgs";
};
iosevka-custom.url = "git+https://git.xenia.me.uk/pixelifytica/iosevka.git";
base16.url = "github:SenchoPens/base16.nix";
tt-schemes = {
url = "github:tinted-theming/schemes";
flake = false;
};
};
outputs = {
self,
nixpkgs,
home-manager,
iosevka-custom,
base16,
tt-schemes,
...
}: let
defaultExtraSpecialArgs = {
system ? "x86_64-linux",
hostname ? "Atlas",
...
}: rec {
inherit hostname;
accentColour = "base07"; # catppuccin lavender
catppuccinVariant = "Mocha";
iosevkaCustom = {
packages = iosevka-custom.outputs.packages.${system};
names = iosevka-custom.outputs.names;
};
fonts = with iosevkaCustom; rec {
sizes = {
applications = 12;
desktop = 10;
popups = 14;
terminal = 12;
};
serif = sansSerif;
sansSerif = {
name = names.iosevka-custom-aile;
package = packages.iosevka-custom-aile;
};
monospace = {
name = names.iosevka-custom-nerdfont;
package = packages.iosevka-custom-nerdfont;
};
};
};
defaultModules = {
username ? "pixelifytica",
hostname ? "Atlas",
...
}: [
base16.homeManagerModule
./home/${hostname}.nix
({...}: {
home = {inherit username;};
scheme = "${tt-schemes}/base16/catppuccin-mocha.yaml";
})
];
in {
packages.x86_64-linux = {inherit (home-manager.packages.x86_64-linux) default;};
devShells.x86_64-linux.default = let
pkgs = import nixpkgs {system = "x86_64-linux";};
in
pkgs.mkShellNoCC {
nativeBuildInputs = [
self.packages.x86_64-linux.default
pkgs.nil
];
};
homeConfigurations = {
# Fallback entry
pixelifytica = home-manager.lib.homeManagerConfiguration {
pkgs = import nixpkgs {system = "x86_64-linux";};
modules = defaultModules {
username = "pixelifytica";
hostname = "Atlas";
};
extraSpecialArgs = defaultExtraSpecialArgs {
system = "x86_64-linux";
hostname = "Atlas";
};
};
# Server
"pixelifytica@Legion" = home-manager.lib.homeManagerConfiguration {
pkgs = import nixpkgs {system = "x86_64-linux";};
modules = defaultModules {
username = "pixelifytica";
hostname = "Legion";
};
extraSpecialArgs = defaultExtraSpecialArgs {
system = "x86_64-linux";
hostname = "Legion";
};
};
# Personal
"pixelifytica@Northstar" = home-manager.lib.homeManagerConfiguration {
pkgs = import nixpkgs {system = "x86_64-linux";};
modules = defaultModules {
username = "pixelifytica";
hostname = "Northstar";
};
extraSpecialArgs = defaultExtraSpecialArgs {
system = "x86_64-linux";
hostname = "Northstar";
};
};
"pixelifytica@Vanguard" = home-manager.lib.homeManagerConfiguration {
pkgs = import nixpkgs {system = "x86_64-linux";};
modules = defaultModules {
username = "pixelifytica";
hostname = "Vanguard";
};
extraSpecialArgs = defaultExtraSpecialArgs {
system = "x86_64-linux";
hostname = "Vanguard";
};
};
# Work
2024-05-20 07:11:48 +01:00
"elitherl@Tone" = home-manager.lib.homeManagerConfiguration {
pkgs = import nixpkgs {system = "x86_64-linux";};
modules = defaultModules {
username = "elitherl";
2024-05-20 07:11:48 +01:00
hostname = "Tone";
};
extraSpecialArgs = defaultExtraSpecialArgs {
system = "x86_64-linux";
2024-05-20 07:11:48 +01:00
hostname = "Tone";
};
};
"elitherl@Scorch" = home-manager.lib.homeManagerConfiguration {
pkgs = import nixpkgs {system = "x86_64-linux";};
modules = defaultModules {
username = "elitherl";
hostname = "Scorch";
};
extraSpecialArgs = defaultExtraSpecialArgs {
system = "x86_64-linux";
hostname = "Scorch";
};
};
};
};
}