Nixpkgs-patcher not working

Hi,

I’m struggling using nixpkgs-patcher

{
  description = "Geob’s flake";

  nixConfig = {
    extra-substituters = [
      "https://lan-mouse.cachix.org/"
      "https://noctalia.cachix.org"
    ];
    extra-trusted-public-keys = [
      "lan-mouse.cachix.org-1:KlE2AEZUgkzNKM7BIzMQo8w9yJYqUpor1CAUNRY6OyM="
      "noctalia.cachix.org-1:pCOR47nnMEo5thcxNDtzWpOxNFQsBRglJzxWPp3dkU4="
    ];
  };
  inputs = {
    nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
    nixpkgs-patcher = {
      url = "github:gepbird/nixpkgs-patcher";
    };
    nixpkgs-darktable = {
      url = "https://github.com/NixOS/nixpkgs/pull/534312.diff";
      flake = false;
    };

    home-manager = {
      url = "github:nix-community/home-manager";
      inputs.nixpkgs.follows = "nixpkgs";
    };

    zen-browser = {
      url = "github:0xc000022070/zen-browser-flake";
      inputs = {
        nixpkgs.follows = "nixpkgs";
      };
    };

    sops-nix = {
      url = "github:Mic92/sops-nix";
      inputs.nixpkgs.follows = "nixpkgs";
    };

    lan-mouse.url = "github:feschber/lan-mouse/v0.11.0";
  };

  outputs =
    {
      self,
      nixpkgs,
      nixpkgs-patcher,
      home-manager,
      sops-nix,
      ...
    }@inputs:
    let
      inherit (self) outputs;
    in
    {
      nixosConfigurations = {
        delorean = nixpkgs-patcher.lib.nixosSystem {
          # inherit system;
          specialArgs = {
            inherit inputs outputs;
          };
          nixpkgsPatcher.inputs = inputs;
          modules = [
            ./nixos/delorean
            sops-nix.nixosModules.sops
          ];
        };
        kitt = nixpkgs.lib.nixosSystem {
          specialArgs = {
            inherit inputs outputs;
          };
          modules = [
            ./nixos/kitt
            sops-nix.nixosModules.sops
          ];
        };
      };
    };
}

But it doesn’t seems to fetch the PR I want (darktable), what am I missing?

You have an input called nixpkgs-darktable, but where are you using it?
And how do you know it’s not working?

Also, I see for kitt you’re still using nixpkgs.lib instead of nixpkgs-patcher.lib.

You need to prefix it with nixpkgs-patch-. Right now it’s only prefixed with nixpkgs-.

1 Like