ini𝖔 𝕞𝐚𝔢 b𝖁𝖘𝖋𝖗𝖆𝕊t commit
This commit is contained in:
commit
37729aa76e
26 changed files with 5634 additions and 0 deletions
44
flake.nix
Normal file
44
flake.nix
Normal file
|
@ -0,0 +1,44 @@
|
|||
{
|
||||
description = "amdl";
|
||||
|
||||
inputs = {
|
||||
flake-utils.url = "github:numtide/flake-utils";
|
||||
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, flake-utils }:
|
||||
flake-utils.lib.eachDefaultSystem (system:
|
||||
let
|
||||
pkgs = import nixpkgs {
|
||||
inherit system;
|
||||
};
|
||||
package = builtins.fromJSON (builtins.readFile ./package.json);
|
||||
in {
|
||||
packages = flake-utils.lib.flattenTree rec {
|
||||
default = amdl;
|
||||
amdl = pkgs.buildNpmPackage {
|
||||
pname = package.name;
|
||||
inherit (package) version;
|
||||
|
||||
# uncomment this and let the build fail, then get the current hash
|
||||
# very scuffed but endorsed!
|
||||
#npmDepsHash = "sha256-AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=";
|
||||
npmDepsHash = "sha256-XCGUKgLZxW7MonHswkp7mbvgeUlRCgBE3WnRjElf44Q=";
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out
|
||||
mv ./dist/* $out/
|
||||
'';
|
||||
|
||||
src = ./.;
|
||||
};
|
||||
};
|
||||
|
||||
devShells.default = pkgs.mkShell {
|
||||
packages = with pkgs; [
|
||||
nodejs
|
||||
nodePackages.npm
|
||||
];
|
||||
};
|
||||
});
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue