49 lines
1.5 KiB
Nix
49 lines
1.5 KiB
Nix
|
{
|
||
|
description = "SZF1_13_Frontend_CourseController";
|
||
|
|
||
|
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.05"; # default packages
|
||
|
|
||
|
outputs =
|
||
|
{ self, nixpkgs }:
|
||
|
let
|
||
|
supportedSystems = [
|
||
|
"x86_64-linux"
|
||
|
"aarch64-linux"
|
||
|
"x86_64-darwin"
|
||
|
"aarch64-darwin"
|
||
|
];
|
||
|
forEachSupportedSystem =
|
||
|
f:
|
||
|
nixpkgs.lib.genAttrs supportedSystems (
|
||
|
system:
|
||
|
f {
|
||
|
pkgs = import nixpkgs { inherit system; };
|
||
|
}
|
||
|
);
|
||
|
in
|
||
|
{
|
||
|
devShells = forEachSupportedSystem (
|
||
|
{ pkgs }:
|
||
|
{
|
||
|
default = pkgs.mkShell {
|
||
|
shellHook = with pkgs.nodePackages.prisma; ''
|
||
|
export PRISMA_MIGRATION_ENGINE_BINARY="${pkgs.prisma-engines}/bin/migration-engine"
|
||
|
export PRISMA_SCHEMA_ENGINE_BINARY="${pkgs.prisma-engines}/bin/schema-engine"
|
||
|
export PRISMA_QUERY_ENGINE_BINARY="${pkgs.prisma-engines}/bin/query-engine"
|
||
|
export PRISMA_QUERY_ENGINE_LIBRARY="${pkgs.prisma-engines}/lib/libquery_engine.node"
|
||
|
export PRISMA_INTROSPECTION_ENGINE_BINARY="${pkgs.prisma-engines}/bin/introspection-engine"
|
||
|
export PRISMA_FMT_BINARY="${pkgs.prisma-engines}/bin/prisma-fmt"
|
||
|
export PATH="$PWD/node_modules/.bin:$PATH"
|
||
|
'';
|
||
|
packages = with pkgs; [
|
||
|
nodejs
|
||
|
openssl
|
||
|
nodePackages.prisma
|
||
|
prisma-engines
|
||
|
];
|
||
|
};
|
||
|
}
|
||
|
);
|
||
|
};
|
||
|
}
|