BAPSicle/webstudio.nix
2024-04-03 22:43:26 +01:00

45 lines
932 B
Nix

{ pkgs }:
let
src = pkgs.fetchgit {
url = "https://git.ashhhleyyy.dev/ash/WebStudio";
rev= "6ea63caca50905f6d4f2b80de4005f974bf829b0";
hash = "sha256-ur2T3m3M6GDfpE5/oMXqs/kLd06xMOGOFQu7MI4zfOI=";
};
yarnOfflineCache = pkgs.fetchYarnDeps {
yarnLock = "${src}/yarn.lock";
hash = "sha256-AmKui+Sqyipy4/9lcg8vGWfp9lM2+/fHHDzEWoG8fqw=";
};
in
pkgs.stdenv.mkDerivation {
name = "baps-presenter";
inherit src;
nativeBuildInputs = with pkgs; [
nodejs
yarn
yarn2nix-moretea.fixup_yarn_lock
];
configurePhase = ''
export HOME=$(mktemp -d)
'';
buildPhase = ''
yarn config --offline set yarn-offline-mirror ${yarnOfflineCache}
fixup_yarn_lock yarn.lock
yarn install --offline \
--frozen-lockfile \
--ignore-engines \
--ignore-scripts
patchShebangs .
yarn run build-baps
'';
installPhase = ''
mkdir -p $out
cp -R build/. $out
'';
doDist = false;
}