install home manager and add home.nix
This commit is contained in:
parent
f5208de999
commit
bb1e8ab317
23
flake.nix
23
flake.nix
|
@ -1,13 +1,30 @@
|
||||||
{
|
{
|
||||||
description = "Alex's super mega awesome nixos config";
|
description = "Alex's super mega awesome nixos config";
|
||||||
|
|
||||||
inputs.nixpkgs.url = github:NixOS/nixpkgs/nixos-23.05;
|
inputs = {
|
||||||
|
nixpkgs.url = github:NixOS/nixpkgs/nixos-23.05;
|
||||||
|
home-manager.url = "github:nix-community/home-manager";
|
||||||
|
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
|
||||||
outputs = { self, nixpkgs }@attrs: {
|
outputs = { nixpkgs, home-manager, ... }@attrs: {
|
||||||
nixosConfigurations.nixos76 = nixpkgs.lib.nixosSystem {
|
nixosConfigurations.nixos76 = nixpkgs.lib.nixosSystem {
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
specialArgs = attrs;
|
specialArgs = attrs;
|
||||||
modules = [ ./configuration.nix ];
|
modules = [
|
||||||
|
./configuration.nix
|
||||||
|
home-manager.nixosModules.home-manager
|
||||||
|
{
|
||||||
|
home-manager.useGlobalPkgs = true;
|
||||||
|
home-manager.useUserPackages = true;
|
||||||
|
home-manager.users.alex = import ./home.nix;
|
||||||
|
|
||||||
|
# Optionally, use home-manager.extraSpecialArgs to pass
|
||||||
|
# arguments to home.nix
|
||||||
|
}
|
||||||
|
|
||||||
|
]
|
||||||
|
;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,29 @@
|
||||||
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
# Home Manager needs a bit of information about you and the
|
||||||
|
# paths it should manage.
|
||||||
|
home.username = "alex";
|
||||||
|
home.homeDirectory = "/home/alex";
|
||||||
|
|
||||||
|
# Packages that should be installed to the user profile.
|
||||||
|
home.packages = [
|
||||||
|
|
||||||
|
|
||||||
|
pkgs.htop
|
||||||
|
pkgs.nixpkgs-fmt
|
||||||
|
];
|
||||||
|
|
||||||
|
# This value determines the Home Manager release that your
|
||||||
|
# configuration is compatible with. This helps avoid breakage
|
||||||
|
# when a new Home Manager release introduces backwards
|
||||||
|
# incompatible changes.
|
||||||
|
#
|
||||||
|
# You can update Home Manager without changing this value. See
|
||||||
|
# the Home Manager release notes for a list of state version
|
||||||
|
# changes in each release.
|
||||||
|
home.stateVersion = "23.05";
|
||||||
|
|
||||||
|
# Let Home Manager install and manage itself.
|
||||||
|
programs.home-manager.enable = true;
|
||||||
|
}
|
Loading…
Reference in New Issue