From a1f262186723ee9276aa9a284ac2225c0bdff0ec Mon Sep 17 00:00:00 2001 From: macronova Date: Thu, 9 Nov 2023 19:37:21 -0800 Subject: [PATCH] Use global starship --- common/default.nix | 3 +- common/users.nix | 5 +- flake.lock | 104 +++++++++++++++++++++++++--- flake.nix | 1 + linux/blitzar/gui.nix | 41 +++++------ linux/singularity/configuration.nix | 1 + linux/singularity/default.nix | 1 + 7 files changed, 126 insertions(+), 30 deletions(-) diff --git a/common/default.nix b/common/default.nix index dcbf408..74c448c 100644 --- a/common/default.nix +++ b/common/default.nix @@ -2,8 +2,9 @@ { imports = with inputs; [ - sops-nix.nixosModules.sops home-manager.nixosModules.home-manager + nh.nixosModules.default + sops-nix.nixosModules.sops ] ++ [ ./constants.nix ./secrets.nix diff --git a/common/users.nix b/common/users.nix index a57bd49..8fb47cc 100644 --- a/common/users.nix +++ b/common/users.nix @@ -58,7 +58,10 @@ in }; }; ripgrep.enable = true; - starship.enable = true; + starship = { + enable = true; + enableTransience = true; + }; tealdeer.enable = true; zoxide = { enable = true; diff --git a/flake.lock b/flake.lock index b351080..3adc577 100644 --- a/flake.lock +++ b/flake.lock @@ -68,6 +68,24 @@ "type": "github" } }, + "flake-parts": { + "inputs": { + "nixpkgs-lib": "nixpkgs-lib" + }, + "locked": { + "lastModified": 1698579227, + "narHash": "sha256-KVWjFZky+gRuWennKsbo6cWyo7c/z/VgCte5pR9pEKg=", + "owner": "hercules-ci", + "repo": "flake-parts", + "rev": "f76e870d64779109e41370848074ac4eaa1606ec", + "type": "github" + }, + "original": { + "owner": "hercules-ci", + "repo": "flake-parts", + "type": "github" + } + }, "flake-utils": { "inputs": { "systems": "systems" @@ -142,10 +160,30 @@ "type": "gitlab" } }, + "nh": { + "inputs": { + "flake-parts": "flake-parts", + "nix-filter": "nix-filter", + "nixpkgs": "nixpkgs_5" + }, + "locked": { + "lastModified": 1698826948, + "narHash": "sha256-Th05oofIIhsN2bmJNsb0Xev3+RJgtk8stjHZX9EdWA0=", + "owner": "viperML", + "repo": "nh", + "rev": "23d21975231d569afbe3973eb19d955c650f8f08", + "type": "github" + }, + "original": { + "owner": "viperML", + "repo": "nh", + "type": "github" + } + }, "nix-custom": { "inputs": { "flake-utils": "flake-utils", - "nixpkgs": "nixpkgs_5", + "nixpkgs": "nixpkgs_6", "wallpaper-engine-kde-plugin": "wallpaper-engine-kde-plugin", "yorha-grub-theme": "yorha-grub-theme" }, @@ -163,6 +201,21 @@ "url": "https://forgejo.invariantspace.com/macronova/nix-custom" } }, + "nix-filter": { + "locked": { + "lastModified": 1694857738, + "narHash": "sha256-bxxNyLHjhu0N8T3REINXQ2ZkJco0ABFPn6PIe2QUfqo=", + "owner": "numtide", + "repo": "nix-filter", + "rev": "41fd48e00c22b4ced525af521ead8792402de0ea", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "nix-filter", + "type": "github" + } + }, "nixpkgs": { "locked": { "lastModified": 1687274257, @@ -206,6 +259,24 @@ "type": "indirect" } }, + "nixpkgs-lib": { + "locked": { + "dir": "lib", + "lastModified": 1696019113, + "narHash": "sha256-X3+DKYWJm93DRSdC5M6K5hLqzSya9BjibtBsuARoPco=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "f5892ddac112a1e9b3612c39af1b72987ee5783a", + "type": "github" + }, + "original": { + "dir": "lib", + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, "nixpkgs-stable": { "locked": { "lastModified": 1699110214, @@ -271,15 +342,15 @@ }, "nixpkgs_5": { "locked": { - "lastModified": 1699099776, - "narHash": "sha256-X09iKJ27mGsGambGfkKzqvw5esP1L/Rf8H3u3fCqIiU=", - "owner": "nixos", + "lastModified": 1698611440, + "narHash": "sha256-jPjHjrerhYDy3q9+s5EAsuhyhuknNfowY6yt6pjn9pc=", + "owner": "NixOS", "repo": "nixpkgs", - "rev": "85f1ba3e51676fa8cc604a3d863d729026a6b8eb", + "rev": "0cbe9f69c234a7700596e943bfae7ef27a31b735", "type": "github" }, "original": { - "owner": "nixos", + "owner": "NixOS", "ref": "nixos-unstable", "repo": "nixpkgs", "type": "github" @@ -302,6 +373,22 @@ } }, "nixpkgs_7": { + "locked": { + "lastModified": 1699099776, + "narHash": "sha256-X09iKJ27mGsGambGfkKzqvw5esP1L/Rf8H3u3fCqIiU=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "85f1ba3e51676fa8cc604a3d863d729026a6b8eb", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_8": { "locked": { "lastModified": 1699094435, "narHash": "sha256-YLZ5/KKZ1PyLrm2MO8UxRe4H3M0/oaYqNhSlq6FDeeA=", @@ -324,14 +411,15 @@ "hardware": "hardware", "home-manager": "home-manager", "mailserver": "mailserver", + "nh": "nh", "nix-custom": "nix-custom", - "nixpkgs": "nixpkgs_6", + "nixpkgs": "nixpkgs_7", "sops-nix": "sops-nix" } }, "sops-nix": { "inputs": { - "nixpkgs": "nixpkgs_7", + "nixpkgs": "nixpkgs_8", "nixpkgs-stable": "nixpkgs-stable" }, "locked": { diff --git a/flake.nix b/flake.nix index 12cffa0..e7ad4b4 100644 --- a/flake.nix +++ b/flake.nix @@ -7,6 +7,7 @@ hardware.url = "github:nixos/nixos-hardware"; home-manager.url = "github:nix-community/home-manager"; mailserver.url = "gitlab:simple-nixos-mailserver/nixos-mailserver"; + nh.url = "github:viperML/nh"; nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; nix-custom.url = "git+https://forgejo.invariantspace.com/macronova/nix-custom"; sops-nix.url = "github:Mic92/sops-nix"; diff --git a/linux/blitzar/gui.nix b/linux/blitzar/gui.nix index 0c115e2..35f60f1 100644 --- a/linux/blitzar/gui.nix +++ b/linux/blitzar/gui.nix @@ -33,29 +33,30 @@ }; }; - programs.clash-verge = { - enable = true; - tunMode = true; - autoStart = true; + programs = { + clash-verge = { + enable = true; + tunMode = true; + autoStart = true; + }; + dconf.enable = true; + steam.enable = true; }; - programs.dconf.enable = true; - - programs.steam.enable = true; - - services.colord.enable = true; - - services.xserver = { - enable = true; - displayManager = { - defaultSession = "plasmawayland"; - autoLogin.user = "macronova"; - sddm = { - enable = true; - autoLogin.relogin = true; + services = { + colord.enable = true; + xserver = { + enable = true; + displayManager = { + defaultSession = "plasmawayland"; + autoLogin.user = "macronova"; + sddm = { + enable = true; + autoLogin.relogin = true; + }; }; + desktopManager.plasma5.enable = true; + videoDrivers = [ "amdgpu" ]; }; - desktopManager.plasma5.enable = true; - videoDrivers = [ "amdgpu" ]; }; } diff --git a/linux/singularity/configuration.nix b/linux/singularity/configuration.nix index 00ef68f..d012a72 100644 --- a/linux/singularity/configuration.nix +++ b/linux/singularity/configuration.nix @@ -18,6 +18,7 @@ programs = { fish.enable = true; git.enable = true; + starship.enable = true; }; sops.secrets."users/root/password".neededForUsers = true; diff --git a/linux/singularity/default.nix b/linux/singularity/default.nix index f50210d..3d5af56 100644 --- a/linux/singularity/default.nix +++ b/linux/singularity/default.nix @@ -1,6 +1,7 @@ { inputs, ... }: { imports = with inputs; [ mailserver.nixosModule + nh.nixosModules.default sops-nix.nixosModules.sops ] ++ [ ./caddy.nix