feat(checks): add devShells
All checks were successful
Discord / discord commits (push) Has been skipped

This commit is contained in:
matt1432 2024-12-16 15:02:39 -05:00
parent 9ac0fdb00c
commit 1ce40f2c1a
5 changed files with 51 additions and 30 deletions

View file

@ -4,14 +4,17 @@
}: let
apps = import ./apps {inherit pkgs self;};
devices = import ./devices {inherit pkgs self;};
devShells = import ./devShells {inherit pkgs self;};
packages = import ./packages {inherit pkgs self;};
in {
# Allow homie to serve a binary cache for the devices away from servivi
aptDevices = import ./devices {
aptDevices =
devShells
// (import ./devices {
onlyApt = true;
inherit pkgs self;
};
});
all = apps // devices // packages;
inherit apps packages devices;
all = apps // devices // devShells // packages;
inherit apps devices devShells packages;
}

View file

@ -0,0 +1,10 @@
{
pkgs,
self,
}: let
inherit (pkgs.lib) mapAttrs' nameValuePair;
in
mapAttrs'
(name: shell:
nameValuePair "devShell_${name}" shell)
self.devShells.${pkgs.system}

View file

@ -15,5 +15,6 @@
self.nixosConfigurations;
in
mapAttrs'
(name: config: nameValuePair "device_${name}" config.config.system.build.toplevel)
(name: config:
nameValuePair "device_${name}" config.config.system.build.toplevel)
devices

View file

@ -13,5 +13,6 @@
self.packages.${pkgs.system};
in
mapAttrs'
(name: pkg: nameValuePair "pkg_${name}" pkg)
(name: pkg:
nameValuePair "pkg_${name}" pkg)
packages

View file

@ -145,9 +145,11 @@
import ./apps/nix/packages.nix {inherit pkgs self;});
devShells = perSystem (pkgs: let
inherit (builtins) attrValues;
bumpNpmDeps = pkgs.writeShellApplication {
name = "bumpNpmDeps";
runtimeInputs = builtins.attrValues {
runtimeInputs = attrValues {
inherit
(pkgs)
prefetch-npm-deps
@ -188,19 +190,20 @@
};
node = pkgs.mkShell {
packages =
(builtins.attrValues {
packages = attrValues {
inherit
(pkgs)
nodejs_latest
;
})
++ [bumpNpmDeps];
inherit
bumpNpmDeps
;
};
};
subtitles-dev = pkgs.mkShell {
packages =
(builtins.attrValues {
packages = attrValues {
inherit
(pkgs)
nodejs_latest
@ -211,8 +214,11 @@
(pkgs.nodePackages)
ts-node
;
})
++ [bumpNpmDeps];
inherit
bumpNpmDeps
;
};
};
});