This repository has been archived on 2022-05-16. You can view files and clone it, but cannot push or open issues or pull requests.
go-xkcd-reader/.nix/pkgs.nix

19 lines
481 B
Nix

{ systemChannel ? <nixpkgs>, useFetched ? false }:
let systemPkgs = import systemChannel {
overlays = [ (import ./overlay.nix) ];
};
lib = systemPkgs.lib;
src = import ./sources.nix;
pkgs = import src.nixpkgs {
overlays = [ (import ./overlay.nix) ];
};
in
if (!useFetched && (systemPkgs.gtk4 or null) != null && lib.versionAtLeast systemPkgs.gtk4.version "4.4.0")
# Prefer the system's Nixpkgs if it's new enough.
then systemPkgs
# Else, fetch our own.
else pkgs