27 lines
781 B
Nix
27 lines
781 B
Nix
# SPDX-FileCopyrightText: 2022-2023 Gregor Kleen <gregor@kleen.consulting>
|
|
#
|
|
# SPDX-License-Identifier: AGPL-3.0-or-later
|
|
|
|
{ frontendSource, ... }: final: prev: {
|
|
uniworxWellKnown = prev.stdenv.mkDerivation {
|
|
name = "uniworx-well-known";
|
|
src = frontendSource;
|
|
|
|
phases = ["unpackPhase" "buildPhase" "installPhase" "fixupPhase"];
|
|
|
|
buildPhase = ''
|
|
ln -s ${final.uniworxNodeDependencies}/lib/node_modules ./node_modules
|
|
export PATH="${final.uniworxNodeDependencies}/bin:${prev.exiftool}/bin:$PATH"
|
|
webpack --progress
|
|
'';
|
|
|
|
installPhase = ''
|
|
mkdir -p $out
|
|
cp -r --reflink=auto well-known $out/.nix-well-known
|
|
'';
|
|
|
|
outputHashMode = "recursive";
|
|
outputHash = "sha256-zntsIUu13s5doijk3C8ZniYDlDdHZ5Isbv0SQLNgt08=";
|
|
};
|
|
}
|