{ pkgs , fetchFromGitHub , lib , nix-update-script }: let src = fetchFromGitHub { owner = "nix-community"; repo = "nixpkgs-wayland"; rev = "021a0a37c336730956f5ce741c2a5c0e5c113b40"; hash = "sha256-NiBJ7EgvGmDmXy1MG1r++afIzFJBmir2PQ4wmMNIaWw="; }; flake = import "${src}/flake.nix"; evaluated = flake.outputs { self = evaluated; lib-aggregate.lib = lib // { # mock out flake-utils, which it uses to construct flavored package sets. # we only need the overlay (unflavored) flake-utils.eachSystem = sys: fn: {}; }; }; overlay = evaluated.overlay; final = pkgs.appendOverlays [ overlay ]; in src.overrideAttrs (base: { # attributes required by update scripts pname = "nixpkgs-wayland"; version = "0-unstable-2024-06-08"; src = src; # passthru only nixpkgs-wayland's own packages -- not the whole nixpkgs-with-nixpkgs-wayland-as-overlay: passthru = base.passthru // (overlay final pkgs) // { updateScript = nix-update-script { extraArgs = [ "--version" "branch" ]; }; }; })