Add new nix shell for customer project
This commit is contained in:
parent
ec0b271e2f
commit
4a516a68c1
29
shells/werkraum-media/htt-shell.nix
Normal file
29
shells/werkraum-media/htt-shell.nix
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
{ pkgs ? import <nixpkgs> { } }:
|
||||||
|
|
||||||
|
let
|
||||||
|
compileAssets = pkgs.writeShellApplication {
|
||||||
|
name = "compileAssets";
|
||||||
|
runtimeInputs = [
|
||||||
|
pkgs.nodejs-16_x
|
||||||
|
pkgs.nodePackages.npm
|
||||||
|
];
|
||||||
|
text = ''
|
||||||
|
rm -f "$PROJECT_ROOT/packages/sitepackage/Resources/Public/Stylesheets/main.css"
|
||||||
|
rm -rf "$PROJECT_ROOT/packages/sitepackage/Resources/Public/JavaScripts/main.js"
|
||||||
|
rm -rf "$PROJECT_ROOT/.build/node_modules/"
|
||||||
|
npm ci --prefix="$PROJECT_ROOT/.build/"
|
||||||
|
npm run build --prefix="$PROJECT_ROOT/.build/"
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
in pkgs.mkShell {
|
||||||
|
name = "TYPO3Website";
|
||||||
|
buildInputs = [
|
||||||
|
compileAssets
|
||||||
|
pkgs.nodejs-16_x
|
||||||
|
];
|
||||||
|
|
||||||
|
shellHook = ''
|
||||||
|
export PROJECT_ROOT="$(pwd)"
|
||||||
|
'';
|
||||||
|
}
|
Loading…
Reference in a new issue