Files
inter-hub/devenv.nix
Bernd Worsch 64a9d4eeb4 feat(WP-0016/C1-C4): Layer 2 isolation and clean-base infrastructure
- Add Web/Controller/Prelude.hs (was missing; 8 controllers failed to import it)
- Add .ghci-core and scripts/compile-check-core to compile Layer 1+2 in
  isolation without loading Main.hs or any controller/view (Layer 3)
- Fix Application/Helper/BottleneckDetector.hs: replace coerce :: Id' -> UUID
  with unpackId (IHP Id' wraps a type family; Data.Coerce cannot cross it)
- Fix devenv.nix: add pkgs.nodePackages.tailwindcss so devenv process scripts
  find the tailwindcss binary (devenv v2 builds scripts with only local packages)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-10 15:38:01 +00:00

25 lines
1.2 KiB
Nix

# devenv.nix — required by devenv v2+.
#
# IHP's flake module (flake.nix) provides the full devenv shell via
# `inputs.devenv.flakeModule`: Haskell toolchain, PostgreSQL, ghcid,
# and RunDevServer. This file satisfies devenv v2's file-presence
# requirement and adds project-specific overrides on top.
#
# Duplicates the settings from flake.nix devenv.shells.default so they
# are applied under both devenv v1 (flake path) and devenv v2 (this file).
{ pkgs, lib, config, inputs, ... }:
{
# Resource limits for constrained host (2 CPU / 3.8 GiB RAM).
# -A32m: smaller minor heap, -M2g: hard heap ceiling.
# Note: -N1 omitted intentionally (requires -threaded, breaks IHP tools).
# GHC parallel module compilation is capped via -j1 in .ghci instead.
env.GHCRTS = "-A32m -M2g";
# Make tailwindcss available in process scripts (devenv v2 builds process
# scripts with only packages declared here, not from flake ihp.packages).
packages = [ pkgs.nodePackages.tailwindcss ];
# Tailwind CSS watcher — not part of IHP's core devenv module.
processes.tailwind.exec = "tailwindcss -c tailwind/tailwind.config.js -i ./tailwind/app.css -o static/app.css --watch=always";
}