xinlib: hmmm, need to rethink xinlib.prIsOpen.pkg
This commit is contained in:
parent
6a18340a11
commit
801f50c3c0
@ -25,7 +25,8 @@ let
|
||||
path = [ promnesia hpi ];
|
||||
}];
|
||||
tailscale-systray = xinlib.prIsOpen.pkg 219502
|
||||
(pkgs.callPackage ../pkgs/tailscale-systray.nix { });
|
||||
(pkgs.callPackage ../pkgs/tailscale-systray.nix { })
|
||||
pkgs."tailscale-systray";
|
||||
in with lib; {
|
||||
imports = [ ./gnome.nix ./kde.nix ./xfce.nix ./arcan.nix ];
|
||||
|
||||
@ -63,7 +64,8 @@ in with lib; {
|
||||
(callPackage ../pkgs/kurinto.nix { })
|
||||
];
|
||||
sound.enable = true;
|
||||
environment.systemPackages = with pkgs; [
|
||||
environment.systemPackages = with pkgs;
|
||||
(xinlib.filterList [
|
||||
bc
|
||||
black
|
||||
brave
|
||||
@ -80,7 +82,7 @@ in with lib; {
|
||||
(callPackage ../pkgs/govulncheck.nix { })
|
||||
(callPackage ../configs/helix.nix { })
|
||||
tailscale-systray
|
||||
];
|
||||
]);
|
||||
|
||||
programs = { } // firefox.programs;
|
||||
|
||||
|
@ -1,21 +1,20 @@
|
||||
{ lib, ... }:
|
||||
# TODO: this could be cleaner :D
|
||||
let
|
||||
inherit (builtins) toString readFile fromJSON filter;
|
||||
getPrStatus = pr:
|
||||
let
|
||||
prstr = builtins.toString pr;
|
||||
prStatus =
|
||||
builtins.fromJSON (builtins.readFile ../pull_requests/${prstr}.json);
|
||||
prstr = toString pr;
|
||||
prStatus = fromJSON (readFile ../pull_requests/${prstr}.json);
|
||||
in prStatus;
|
||||
prIsOpen = {
|
||||
pkg = pr: pkg:
|
||||
pkg = pr: localPkg: upstreamPkg:
|
||||
let prStatus = getPrStatus pr;
|
||||
in if prStatus.status == "open" then
|
||||
pkg
|
||||
localPkg
|
||||
else
|
||||
lib.warn "PR: ${
|
||||
builtins.toString pr
|
||||
} (${prStatus.title}) is complete, ignoring pkg..." null;
|
||||
lib.warn
|
||||
"PR: ${toString pr} (${prStatus.title}) is complete, ignoring pkg..."
|
||||
upstreamPkg;
|
||||
|
||||
overlay = pr: overlay:
|
||||
let prStatus = getPrStatus pr;
|
||||
@ -23,10 +22,12 @@ let
|
||||
overlay
|
||||
else
|
||||
lib.warn "PR: ${
|
||||
builtins.toString pr
|
||||
toString pr
|
||||
} (${prStatus.title}) is complete, ignoring overlay..." (_: _: { });
|
||||
};
|
||||
|
||||
filterList = pkgList: filter (x: x != null) pkgList;
|
||||
|
||||
mkCronScript = name: src: ''
|
||||
. /etc/profile;
|
||||
set -x
|
||||
@ -84,7 +85,7 @@ let
|
||||
|
||||
xinlib = {
|
||||
inherit buildVer mkCronScript jobToUserService jobToService buildShell
|
||||
prIsOpen;
|
||||
prIsOpen filterList;
|
||||
};
|
||||
|
||||
in xinlib
|
||||
|
Loading…
Reference in New Issue
Block a user