Archived
1
0
forked from rarias/bscpkgs

3 Commits

Author SHA1 Message Date
3f1a7ae233 Merge all branches 2025-09-26 12:57:54 +02:00
6491ba90ad Add hydraJobs with tests and packages 2025-09-26 12:57:17 +02:00
967cfba8ec Expose our packages in flake packages output 2025-09-26 12:56:37 +02:00

View File

@@ -2,21 +2,17 @@
inputs.nixpkgs.url = "nixpkgs";
outputs = { self, nixpkgs, ...}:
let
system = "x86_64-linux";
pkgs = import nixpkgs {
inherit system;
let
# For now we only support x86
overlays = [ self.overlays.default ];
};
in
system = "x86_64-linux";
pkgs = import nixpkgs {
inherit system;
overlays = [ self.overlays.default ];
};
in
{
bscOverlay = import ./overlay.nix;
overlays.default = self.bscOverlay;
# propagate nixpkgs lib, so we can do bscpkgs.lib
inherit (nixpkgs) lib;
# full nixpkgs with our overlay applied
legacyPackages.${system} = pkgs;
@@ -26,18 +22,21 @@
inherit (builtins) attrNames removeAttrs;
inherit (nixpkgs.lib) flip filterAttrs getAttrs pipe isDerivation;
in
# extract the names of the packages from the overlay, then get the
# actual packages from the full package set with the overlay applied
pipe (self.overlays.default null { inherit (nixpkgs) lib; } ) [
attrNames
(flip getAttrs pkgs)
(flip removeAttrs [ "bsc" ])
(filterAttrs (_: isDerivation))
];
# extract the names of the packages from the overlay, then get the
# actual packages from the full package set with the overlay applied
pipe (self.overlays.default null { inherit (nixpkgs) lib; }) [
attrNames
(flip getAttrs pkgs)
(flip removeAttrs [ "bsc" ])
(filterAttrs (_: isDerivation))
];
hydraJobs = {
inherit (self.legacyPackages.x86_64-linux.bsc-ci) test;
packages = self.packages.${system};
};
};
# propagate nixpkgs lib, so we can do bscpkgs.lib
inherit (nixpkgs) lib;
};
}