depot/nix/pkgs/baserow/web-frontend/regen.sh
Luke Granger-Brown 79ae0d7fef nix/pkgs/baserow/web-frontend: fix
We need to use openssl-legacy-provider to fix an issue with OpenSSL 3.x,
because Webpack (or Nuxt?) need to use deprecated hashes.
2022-11-09 00:35:09 +00:00

19 lines
562 B
Bash
Executable file

#!/usr/bin/env nix-shell
#!nix-shell -p nodePackages.node2nix -i bash
set -euo pipefail
BASEROW_SRC="$(nix-build $HOME/depot --no-out-link -A nix.pkgs.baserow.src)"
node2nix --development -i "$BASEROW_SRC/web-frontend/package.json" --nodejs-12
# Replace args.src with an explicit arg in node-packages.nix.
sed -E -i \
-e 's,^(\s*)src = [^{]+;,\1inherit src;,' \
-e 's|^(\{.*)\}:|\1, src}:|' \
./node-packages.nix
# Pass in src into node-packages.nix
sed -E -i \
-e 's,inherit nodeEnv;,inherit src nodeEnv;,' \
-e 's|}:$|, src}:|' \
./default.nix