I am trying to install blender from the blender-bin
flake using home-manager, which I have working with my system configuration. My home-manager flake.nix
is as follows
{
description = "Home Manager configuration of Aidan Gauland";
inputs = {
# Specify the source of Home Manager and Nixpkgs
home-manager.url = "github:nix-community/home-manager";
nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable";
home-manager.inputs.nixpkgs.follows = "nixpkgs";
};
outputs = { home-manager,
blender-bin,
... }:
let
system = "x86_64-linux";
username = "aidan";
in {
homeConfigurations.${username} = home-manager.lib.homeManagerConfiguration {
configuration = {
imports = [ ./home.nix ];
nixpkgs.overlays = [ blender-bin.overlay ];
};
inherit system username;
homeDirectory = "/home/${username}";
# Update the state version as needed.
stateVersion = "22.05";
};
};
}
And then I have pkgs.blender_3_1
in the home.packages
list in home.nix
. Running home-manager switch --flake /path/to/flake#aidan
produces the following error:
error: attribute 'overlay' missing
at /nix/store/ncsf4qggpgahjbkfkm097lhzjxhfn62a-source/flake.nix:21:32:
20| imports = [ ./home.nix ];
21| nixpkgs.overlays = [ blender-bin.overlay ];
| ^
22| };
My working NixOS flake.nix
looks like this:
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/release-21.11";
};
outputs = { self,
nixpkgs,
blender-bin}: {
nixosConfigurations.blah = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
({ config, pkgs, ... }:
{ nixpkgs.overlays = [ blender-bin.overlay ];
environment.systemPackages = [ pkgs.blender_3_1 ];
})
./configuration.nix
];
};
};
}
What would be the equivalent to this in home-manager?