From bc642392a2af21ff3900a396bc2097ef7812a302 Mon Sep 17 00:00:00 2001 From: Brian Lee Date: Mon, 30 Dec 2024 11:11:11 -0800 Subject: [PATCH] litten: add home-manager --- litten.brenise.dev/Makefile | 6 ++++++ litten.brenise.dev/configuration.nix | 8 ++++++++ litten.brenise.dev/flake.nix | 26 ++++++++++++++++++++++++++ litten.brenise.dev/home.nix | 13 +++++++++++++ 4 files changed, 53 insertions(+) create mode 100644 litten.brenise.dev/Makefile create mode 100644 litten.brenise.dev/flake.nix create mode 100644 litten.brenise.dev/home.nix diff --git a/litten.brenise.dev/Makefile b/litten.brenise.dev/Makefile new file mode 100644 index 0000000..c51a096 --- /dev/null +++ b/litten.brenise.dev/Makefile @@ -0,0 +1,6 @@ +# makefiles require tabs, not spaces +# :set noexpandtab + +.PHONY: update +update: + home-manager switch --flake .#plebconf diff --git a/litten.brenise.dev/configuration.nix b/litten.brenise.dev/configuration.nix index ddc433a..58917bb 100644 --- a/litten.brenise.dev/configuration.nix +++ b/litten.brenise.dev/configuration.nix @@ -10,8 +10,11 @@ in { imports = [ ./hardware-configuration.nix + ]; + nix.settings.experimental-features = [ "nix-command" "flakes" ]; + nixpkgs.config = { allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [ @@ -21,6 +24,7 @@ in "vscode" "terraform" "zoom" + "charlatan3" ]; }; nixpkgs.overlays = [ @@ -101,11 +105,14 @@ in "glance" ]; packages = with pkgs; [ + binutils chromium coreutils # base64 element-desktop firefox gimp + gnumake + home-manager jellyfin-media-player kate # kwrite kdenlive @@ -170,6 +177,7 @@ in }; }; +# home-manager.users.blee = { }; environment = { systemPackages = with pkgs; [ diff --git a/litten.brenise.dev/flake.nix b/litten.brenise.dev/flake.nix new file mode 100644 index 0000000..5f41611 --- /dev/null +++ b/litten.brenise.dev/flake.nix @@ -0,0 +1,26 @@ +{ + description = "Home Manager configuration"; + + inputs = { + nixpkgs.url = "nixpkgs/nixos-23.11"; + + home-manager = { + url = "github:nix-community/home-manager/release-23.11"; + inputs.nixpkgs.follows = "nixpkgs"; + }; + }; + + outputs = { nixpkgs, home-manager, ... }: + let + lib = nixpkgs.lib; + system = "x86_64-linux"; + pkgs = import nixpkgs { inherit system; }; + in { + homeConfigurations = { + plebconf = home-manager.lib.homeManagerConfiguration { + inherit pkgs; + modules = [ ./home.nix ]; + }; + }; + }; +} \ No newline at end of file diff --git a/litten.brenise.dev/home.nix b/litten.brenise.dev/home.nix new file mode 100644 index 0000000..bd53cac --- /dev/null +++ b/litten.brenise.dev/home.nix @@ -0,0 +1,13 @@ +{ lib, pkgs, ... }: +{ + home = { + packages = with pkgs; [ + hello + ]; + + username = "blee"; + homeDirectory = "/home/${username}"; + + stateVersion = "23.11"; + }; +} \ No newline at end of file