From 2e9254f4df03f356e447b37fff9b9fbc852145e9 Mon Sep 17 00:00:00 2001 From: Ari Sosnovsky Date: Fri, 2 Aug 2024 12:50:48 -0400 Subject: [PATCH] added lix + stable bigbox --- configs/alacritty/alacritty.toml | 6 +++ configs/alacritty/themes | 1 + flake.lock | 86 +++++++++++++++++++++++++++++++- flake.nix | 39 +++++++++++---- modules/lib.nix | 5 +- 5 files changed, 124 insertions(+), 13 deletions(-) create mode 160000 configs/alacritty/themes diff --git a/configs/alacritty/alacritty.toml b/configs/alacritty/alacritty.toml index 543e599..113df87 100644 --- a/configs/alacritty/alacritty.toml +++ b/configs/alacritty/alacritty.toml @@ -1,5 +1,10 @@ + live_config_reload = true +import = [ + "~/.config/alacritty/themes/themes/nord.toml" +] + [window] title = "Terminal" blur = true @@ -16,3 +21,4 @@ args = [ "-c", "tmux attach || tmux" ] + diff --git a/configs/alacritty/themes b/configs/alacritty/themes new file mode 160000 index 0000000..4091fdd --- /dev/null +++ b/configs/alacritty/themes @@ -0,0 +1 @@ +Subproject commit 4091fddff8da892d5594e94116927c7445620867 diff --git a/flake.lock b/flake.lock index ba2661e..babc069 100644 --- a/flake.lock +++ b/flake.lock @@ -1,5 +1,38 @@ { "nodes": { + "flake-utils": { + "inputs": { + "systems": "systems" + }, + "locked": { + "lastModified": 1710146030, + "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, + "flakey-profile": { + "locked": { + "lastModified": 1712898590, + "narHash": "sha256-FhGIEU93VHAChKEXx905TSiPZKga69bWl1VB37FK//I=", + "owner": "lf-", + "repo": "flakey-profile", + "rev": "243c903fd8eadc0f63d205665a92d4df91d42d9d", + "type": "github" + }, + "original": { + "owner": "lf-", + "repo": "flakey-profile", + "type": "github" + } + }, "home-manager": { "inputs": { "nixpkgs": [ @@ -21,6 +54,41 @@ "type": "github" } }, + "lix": { + "flake": false, + "locked": { + "lastModified": 1720626042, + "narHash": "sha256-f8k+BezKdJfmE+k7zgBJiohtS3VkkriycdXYsKOm3sc=", + "rev": "2a4376be20d70feaa2b0e640c5041fb66ddc67ed", + "type": "tarball", + "url": "https://git.lix.systems/api/v1/repos/lix-project/lix/archive/2a4376be20d70feaa2b0e640c5041fb66ddc67ed.tar.gz" + }, + "original": { + "type": "tarball", + "url": "https://git.lix.systems/lix-project/lix/archive/2.90.0.tar.gz" + } + }, + "lix-module": { + "inputs": { + "flake-utils": "flake-utils", + "flakey-profile": "flakey-profile", + "lix": "lix", + "nixpkgs": [ + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1720641669, + "narHash": "sha256-yEO2cGNgzm9x/XxiDQI+WckSWnZX63R8aJLBRSXtYNE=", + "rev": "5c48c833c15bb80d127a398a8c2484d42fdd8257", + "type": "tarball", + "url": "https://git.lix.systems/api/v1/repos/lix-project/nixos-module/archive/5c48c833c15bb80d127a398a8c2484d42fdd8257.tar.gz" + }, + "original": { + "type": "tarball", + "url": "https://git.lix.systems/lix-project/nixos-module/archive/2.90.0.tar.gz" + } + }, "nix-darwin": { "inputs": { "nixpkgs": [ @@ -76,10 +144,11 @@ "root": { "inputs": { "home-manager": "home-manager", + "lix-module": "lix-module", "nix-darwin": "nix-darwin", "nixos-hardware": "nixos-hardware", "nixpkgs": "nixpkgs", - "systems": "systems", + "systems": "systems_2", "unstable": "unstable", "unstable-home-manager": "unstable-home-manager" } @@ -99,6 +168,21 @@ "type": "github" } }, + "systems_2": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + }, "unstable": { "locked": { "lastModified": 1722256103, diff --git a/flake.nix b/flake.nix index cc23a8a..b7c982d 100644 --- a/flake.nix +++ b/flake.nix @@ -1,9 +1,17 @@ { inputs = { + # Hardware nixos-hardware.url = "github:NixOS/nixos-hardware/master"; + systems.url = "github:nix-systems/default"; + # Nixpkgs unstable.url = "github:NixOS/nixpkgs/master"; nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.05"; - systems.url = "github:nix-systems/default"; + # Lix + lix-module = { + url = "https://git.lix.systems/lix-project/nixos-module/archive/2.90.0.tar.gz"; + inputs.nixpkgs.follows = "nixpkgs"; + }; + # Home manager home-manager = { url = "github:nix-community/home-manager/release-24.05"; inputs.nixpkgs.follows = "nixpkgs"; @@ -12,6 +20,7 @@ url = "github:nix-community/home-manager/master"; inputs.nixpkgs.follows = "unstable"; }; + # Macos nix-darwin = { url = "github:LnL7/nix-darwin"; inputs.nixpkgs.follows = "nixpkgs"; @@ -22,11 +31,12 @@ { self , nixos-hardware , nixpkgs - , home-manager - , nix-darwin , systems , unstable + , lix-module + , home-manager , unstable-home-manager + , nix-darwin }: let user = { @@ -57,11 +67,13 @@ nixpkgs = nixpkgs; home-manager = home-manager; nix-darwin = nix-darwin; + lix-module = lix-module; }); unstableLib = (import modules/lib.nix { nixpkgs = unstable; home-manager = unstable-home-manager; nix-darwin = nix-darwin; + lix-module = lix-module; }); eachSystem = nixpkgs.lib.genAttrs (import systems); unstablePkgs = eachSystem (system: @@ -164,16 +176,21 @@ # NIXOS Homelab - BIGBOX1 # ------------- - nixosConfigurations."hl-bigbox1" = unstableLib.makeNixOsModule (hlCommonSettings // { - systemStateVersion = "24.05"; + nixosConfigurations."hl-bigbox1" = makeHLService { hostName = "hl-bigbox1"; - home-manager = { - enable = true; - enableDevelopmentKit = false; - version = "24.11"; - }; configuration = (import ./hosts/hl-bigbox1.nix { user = user; }); - }); + systemStateVersion = "24.05"; + }; + # unstableLib.makeNixOsModule (hlCommonSettings // { + # systemStateVersion = "24.05"; + # hostName = "hl-bigbox1"; + # home-manager = { + # enable = true; + # enableDevelopmentKit = false; + # version = "24.11"; + # }; + # configuration = (import ./hosts/hl-bigbox1.nix { user = user; }); + # }); # NIXOS Homelab - minipc1 # ------------- diff --git a/modules/lib.nix b/modules/lib.nix index 507d59a..e8ba925 100644 --- a/modules/lib.nix +++ b/modules/lib.nix @@ -1,18 +1,20 @@ { nixpkgs , home-manager , nix-darwin +, lix-module }: let makeImports = { attrs , home-manager-modules + , extraConfiguration ? [ ] }: (if (isNull attrs.configuration) then [ ] else [ attrs.configuration ]) ++ [ (import ./main.nix attrs) ] ++ (if attrs.home-manager.enable then home-manager-modules else - [ ]); + [ ]) ++ extraConfiguration; in { makeNixOsModule = @@ -25,6 +27,7 @@ in modules = (makeImports { attrs = attrs; home-manager-modules = [ home-manager.nixosModules.default ]; + extraConfiguration = [ lix-module.nixosModules.default ]; }); }; makeNixOsModuleMaker =