Compare commits

..

No commits in common. "6a4c1b34bf84735b6cbef75cf3a29c6a46851a74" and "743258bb44e2af77798ee74c9d4f6ec2d895eb9f" have entirely different histories.

6 changed files with 156 additions and 166 deletions

209
flake.nix
View file

@ -12,7 +12,10 @@
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
hardware.url = "github:nixos/nixos-hardware"; hardware = {
url = "github:nixos/nixos-hardware";
inputs.nixpkgs.follows = "nixpkgs";
};
disko = { disko = {
url = "github:nix-community/disko"; url = "github:nix-community/disko";
@ -70,115 +73,117 @@
}; };
}; };
outputs = { outputs =
self, { self
nixpkgs, , nixpkgs
home-manager, , home-manager
... , ...
} @ inputs: let } @ inputs:
inherit (self) outputs; let
# Supported systems for your flake packages, shell, etc. inherit (self) outputs;
systems = [ # Supported systems for your flake packages, shell, etc.
"aarch64-linux" systems = [
"i686-linux" "aarch64-linux"
"x86_64-linux" "i686-linux"
"aarch64-darwin" "x86_64-linux"
"x86_64-darwin" "aarch64-darwin"
]; "x86_64-darwin"
# This is a function that generates an attribute by calling a function you ];
# pass to it, with each system as an argument # This is a function that generates an attribute by calling a function you
forAllSystems = nixpkgs.lib.genAttrs systems; # pass to it, with each system as an argument
vars = import ./vars.nix; forAllSystems = nixpkgs.lib.genAttrs systems;
in { vars = import ./vars.nix;
# Your custom packages in
# Accessible through 'nix build', 'nix shell', etc {
packages = forAllSystems (system: import ./pkgs nixpkgs.legacyPackages.${system}); # Your custom packages
# Formatter for your nix files, available through 'nix fmt' # Accessible through 'nix build', 'nix shell', etc
# Other options beside 'alejandra' include 'nixpkgs-fmt' packages = forAllSystems (system: import ./pkgs nixpkgs.legacyPackages.${system});
formatter = forAllSystems (system: nixpkgs.legacyPackages.${system}.alejandra); # Formatter for your nix files, available through 'nix fmt'
# Other options beside 'alejandra' include 'nixpkgs-fmt'
formatter = forAllSystems (system: nixpkgs.legacyPackages.${system}.alejandra);
# Your custom packages and modifications, exported as overlays # Your custom packages and modifications, exported as overlays
overlays = import ./overlays {inherit inputs;}; overlays = import ./overlays { inherit inputs; };
# Reusable nixos modules you might want to export # Reusable nixos modules you might want to export
# These are usually stuff you would upstream into nixpkgs # These are usually stuff you would upstream into nixpkgs
nixosModules = import ./modules/nixos; nixosModules = import ./modules/nixos;
# Reusable home-manager modules you might want to export # Reusable home-manager modules you might want to export
# These are usually stuff you would upstream into home-manager # These are usually stuff you would upstream into home-manager
homeManagerModules = import ./modules/home-manager; homeManagerModules = import ./modules/home-manager;
# NixOS configuration entrypoint # NixOS configuration entrypoint
# Available through 'nixos-rebuild --flake .#your-hostname' # Available through 'nixos-rebuild --flake .#your-hostname'
nixosConfigurations = { nixosConfigurations = {
adalbert = nixpkgs.lib.nixosSystem { adalbert = nixpkgs.lib.nixosSystem {
specialArgs = {inherit inputs outputs vars;}; specialArgs = { inherit inputs outputs vars; };
modules = [ modules = [
./hosts/adalbert ./hosts/adalbert
]; ];
}; };
ludwig = nixpkgs.lib.nixosSystem { ludwig = nixpkgs.lib.nixosSystem {
specialArgs = {inherit inputs outputs vars;}; specialArgs = { inherit inputs outputs vars; };
modules = [ modules = [
./hosts/ludwig ./hosts/ludwig
]; ];
}; };
leopold = nixpkgs.lib.nixosSystem { leopold = nixpkgs.lib.nixosSystem {
specialArgs = {inherit inputs outputs vars;}; specialArgs = { inherit inputs outputs vars; };
modules = [ modules = [
./hosts/leopold ./hosts/leopold
]; ];
}; };
franz = nixpkgs.lib.nixosSystem { franz = nixpkgs.lib.nixosSystem {
specialArgs = {inherit inputs outputs vars;}; specialArgs = { inherit inputs outputs vars; };
modules = [ modules = [
./hosts/franz ./hosts/franz
]; ];
}; };
# build with nix build .#nixosConfigurations.eustachius.config.system.build.sdImage # build with nix build .#nixosConfigurations.eustachius.config.system.build.sdImage
eustachius = nixpkgs.lib.nixosSystem { eustachius = nixpkgs.lib.nixosSystem {
system = "aarch64-linux"; system = "aarch64-linux";
modules = [ modules = [
"${nixpkgs}/nixos/modules/installer/sd-card/sd-image-aarch64-installer.nix" "${nixpkgs}/nixos/modules/installer/sd-card/sd-image-aarch64-installer.nix"
./hosts/eustachius ./hosts/eustachius
# extra config for sdImage generator # extra config for sdImage generator
{ {
sdImage.compressImage = false; sdImage.compressImage = false;
} }
]; ];
};
}; };
};
# Standalone home-manager configuration entrypoint # Standalone home-manager configuration entrypoint
# Available through 'home-manager --flake .#your-username@your-hostname' # Available through 'home-manager --flake .#your-username@your-hostname'
homeConfigurations = { homeConfigurations = {
"${vars.user}@adalbert" = home-manager.lib.homeManagerConfiguration { "${vars.user}@adalbert" = home-manager.lib.homeManagerConfiguration {
pkgs = nixpkgs.legacyPackages.x86_64-linux; # Home-manager requires 'pkgs' instance
extraSpecialArgs = { inherit inputs outputs vars; };
modules = [
./home/adalbert.nix
];
};
};
"${vars.user}@ludwig" = home-manager.lib.homeManagerConfiguration {
pkgs = nixpkgs.legacyPackages.x86_64-linux; # Home-manager requires 'pkgs' instance pkgs = nixpkgs.legacyPackages.x86_64-linux; # Home-manager requires 'pkgs' instance
extraSpecialArgs = {inherit inputs outputs vars;}; extraSpecialArgs = { inherit inputs outputs vars; };
modules = [ modules = [
./home/adalbert.nix ./home/ludwig.nix
]; ];
}; };
"${vars.user}@franz" = home-manager.lib.homeManagerConfiguration {
pkgs = nixpkgs.legacyPackages.x86_64-linux; # Home-manager requires 'pkgs' instance
extraSpecialArgs = { inherit inputs outputs vars; };
modules = [
./home/franz.nix
];
};
# "${vars.user}@eustachius" = home-manager.lib.homeManagerConfiguration {
# pkgs = nixpkgs.legacyPackages.aarch64-linux; # Home-manager requires 'pkgs' instance
# extraSpecialArgs = {inherit inputs outputs vars;};
# modules = [
# ./home/eustachius.nix
# ];
# };
}; };
"${vars.user}@ludwig" = home-manager.lib.homeManagerConfiguration {
pkgs = nixpkgs.legacyPackages.x86_64-linux; # Home-manager requires 'pkgs' instance
extraSpecialArgs = {inherit inputs outputs vars;};
modules = [
./home/ludwig.nix
];
};
"${vars.user}@franz" = home-manager.lib.homeManagerConfiguration {
pkgs = nixpkgs.legacyPackages.x86_64-linux; # Home-manager requires 'pkgs' instance
extraSpecialArgs = {inherit inputs outputs vars;};
modules = [
./home/franz.nix
];
};
# "${vars.user}@eustachius" = home-manager.lib.homeManagerConfiguration {
# pkgs = nixpkgs.legacyPackages.aarch64-linux; # Home-manager requires 'pkgs' instance
# extraSpecialArgs = {inherit inputs outputs vars;};
# modules = [
# ./home/eustachius.nix
# ];
# };
};
} }

View file

@ -17,7 +17,6 @@
key = "<leader>ch"; key = "<leader>ch";
action = "<cmd>noh<CR>"; action = "<cmd>noh<CR>";
options = { options = {
silent = true;
desc = "Clear Highlighting"; desc = "Clear Highlighting";
}; };
} }
@ -42,7 +41,6 @@
key = "<C-n>"; key = "<C-n>";
action = "<Cmd>Neotree toggle<CR>"; action = "<Cmd>Neotree toggle<CR>";
options = { options = {
silent = true;
desc = "Toggle Neotree"; desc = "Toggle Neotree";
}; };
} }
@ -83,7 +81,6 @@
key = "<c-k>"; key = "<c-k>";
action = ":wincmd k<CR>"; action = ":wincmd k<CR>";
options = { options = {
silent = true;
desc = "Go Up"; desc = "Go Up";
}; };
} }
@ -92,7 +89,6 @@
key = "<c-j>"; key = "<c-j>";
action = ":wincmd j<CR>"; action = ":wincmd j<CR>";
options = { options = {
silent = true;
desc = "Go Down"; desc = "Go Down";
}; };
} }
@ -101,7 +97,6 @@
key = "<c-h>"; key = "<c-h>";
action = ":wincmd h<CR>"; action = ":wincmd h<CR>";
options = { options = {
silent = true;
desc = "Go Left"; desc = "Go Left";
}; };
} }
@ -110,7 +105,6 @@
key = "<c-l>"; key = "<c-l>";
action = ":wincmd l<CR>"; action = ":wincmd l<CR>";
options = { options = {
silent = true;
desc = "Go Right"; desc = "Go Right";
}; };
} }

View file

@ -1,28 +1,24 @@
{ {
programs.nixvim.plugins = { programs.nixvim.plugins.lsp = {
rustaceanvim.enable = true; enable = true;
inlayHints = true;
lsp = { servers = {
enable = true; ts_ls.enable = true; # TS/JS
inlayHints = true; cssls.enable = true; # CSS
html.enable = true; # HTML
pyright.enable = true; # Python
marksman.enable = true; # Markdown
nil_ls.enable = true; # Nix
dockerls.enable = true; # Docker
bashls.enable = true; # Bash
clangd.enable = true; # C/C++
yamlls.enable = true; # YAML
servers = { lua_ls = {
ts_ls.enable = true; # TS/JS # Lua
cssls.enable = true; # CSS enable = true;
html.enable = true; # HTML settings.telemetry.enable = false;
pyright.enable = true; # Python
marksman.enable = true; # Markdown
nil_ls.enable = true; # Nix
dockerls.enable = true; # Docker
bashls.enable = true; # Bash
clangd.enable = true; # C/C++
yamlls.enable = true; # YAML
lua_ls = {
# Lua
enable = true;
settings.telemetry.enable = false;
};
}; };
}; };
}; };

View file

@ -1,4 +1,4 @@
{pkgs, ...}: { { pkgs, ... }: {
programs.nixvim.plugins = { programs.nixvim.plugins = {
lualine.enable = true; lualine.enable = true;
oil.enable = true; oil.enable = true;
@ -87,12 +87,12 @@
todo-comments = { todo-comments = {
enable = true; enable = true;
settings.colors = { settings.colors = {
error = ["DiagnosticError" "ErrorMsg" "#DC2626"]; error = [ "DiagnosticError" "ErrorMsg" "#DC2626" ];
warning = ["DiagnosticWarn" "WarningMsg" "#FBBF24"]; warning = [ "DiagnosticWarn" "WarningMsg" "#FBBF24" ];
info = ["DiagnosticInfo" "#2563EB"]; info = [ "DiagnosticInfo" "#2563EB" ];
hint = ["DiagnosticHint" "#10B981"]; hint = [ "DiagnosticHint" "#10B981" ];
default = ["Identifier" "#7C3AED"]; default = [ "Identifier" "#7C3AED" ];
test = ["Identifier" "#FF00FF"]; test = [ "Identifier" "#FF00FF" ];
}; };
}; };

View file

@ -1,10 +1,9 @@
{ { inputs
inputs, , pkgs
pkgs, , vars
vars, , ...
...
}: { }: {
imports = [inputs.arkenfox.hmModules.default]; imports = [ inputs.arkenfox.hmModules.default ];
home.file.".mozilla/native-messaging-hosts/org.kde.plasma.browser_integration.json".source = "${pkgs.plasma5Packages.plasma-browser-integration}/lib/mozilla/native-messaging-hosts/org.kde.plasma.browser_integration.json"; home.file.".mozilla/native-messaging-hosts/org.kde.plasma.browser_integration.json".source = "${pkgs.plasma5Packages.plasma-browser-integration}/lib/mozilla/native-messaging-hosts/org.kde.plasma.browser_integration.json";
programs.firefox = { programs.firefox = {
@ -48,7 +47,7 @@
]; ];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg"; icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = ["@np"]; definedAliases = [ "@np" ];
}; };
"Home Manager" = { "Home Manager" = {
@ -65,7 +64,7 @@
]; ];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg"; icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = ["@hm"]; definedAliases = [ "@hm" ];
}; };
"Searx" = { "Searx" = {
@ -82,7 +81,7 @@
]; ];
iconUpdateURL = "https://paulgo.io/favicon.ico"; iconUpdateURL = "https://paulgo.io/favicon.ico";
definedAliases = ["@sx"]; definedAliases = [ "@sx" ];
}; };
"Amazon" = { "Amazon" = {
@ -99,7 +98,7 @@
]; ];
iconUpdateURL = "https://amazon.de/favicon.ico"; iconUpdateURL = "https://amazon.de/favicon.ico";
definedAliases = ["@a"]; definedAliases = [ "@a" ];
}; };
"YouTube" = { "YouTube" = {
@ -116,7 +115,7 @@
]; ];
iconUpdateURL = "https://piped.video/favicon.ico"; iconUpdateURL = "https://piped.video/favicon.ico";
definedAliases = ["yt"]; definedAliases = [ "yt" ];
}; };
}; };
search.force = true; search.force = true;
@ -191,9 +190,9 @@
}; };
xdg.mimeApps.defaultApplications = { xdg.mimeApps.defaultApplications = {
"text/html" = ["firefox.desktop"]; "text/html" = [ "firefox.desktop" ];
"text/xml" = ["firefox.desktop"]; "text/xml" = [ "firefox.desktop" ];
"x-scheme-handler/http" = ["firefox.desktop"]; "x-scheme-handler/http" = [ "firefox.desktop" ];
"x-scheme-handler/https" = ["firefox.desktop"]; "x-scheme-handler/https" = [ "firefox.desktop" ];
}; };
} }

View file

@ -1,21 +1,17 @@
# Do not modify this file! It was generated by nixos-generate-config # Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes # and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead. # to /etc/nixos/configuration.nix instead.
{ { config, lib, pkgs, modulesPath, ... }:
config,
lib,
pkgs,
modulesPath,
...
}: {
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = ["xhci_pci" "thunderbolt" "nvme" "usb_storage" "sd_mod"]; {
boot.initrd.kernelModules = ["dm-snapshot"]; imports =
boot.kernelModules = ["kvm-intel"]; [ (modulesPath + "/installer/scan/not-detected.nix")
boot.extraModulePackages = []; ];
boot.initrd.availableKernelModules = [ "xhci_pci" "thunderbolt" "nvme" "usb_storage" "sd_mod" ];
boot.initrd.kernelModules = [ "dm-snapshot" ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking # Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's # (the default) this is the recommended approach. When using systemd-networkd it's