Hi,
I have created a flake to wrap a software ds9
.
I referred it in my /etc/nixos/flake.nix
as
{
description = "A simple NixOS flake";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.05";
home-manager = {
url = "github:nix-community/home-manager/release-25.05";
inputs.nixpkgs.follows = "nixpkgs";
};
ds9-flake={url = "github:astrojhgu/ds9-flake"; #####<---HERE is the ds9 flake
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = { self, nixpkgs, home-manager, ... }@inputs: {
nixosConfigurations.laptop = nixpkgs.lib.nixosSystem rec {
system = "x86_64-linux";
specialArgs = {
myinputs=inputs;
};
modules = [
# Import the previous configuration.nix we used,
# so the old configuration file still takes effect
./configuration.nix
home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.astrojhgu = import ./users/astrojhgu.nix;
}
];
};
};
}
I’m able to add it to the system’s package tree in the /etc/nixos/configuration.nix
as
{ config, pkgs, python-packages, myinputs, ... }:
{
environment.systemPackages = with pkgs; [
###...
###...
###...
myinputs.ds9-flake.packages.${pkgs.system}.default
];
}
But I cannot find a method to declare this package in my home-manager configuration.
Do anyone know how to do this?
Thanks!