{ lib, fetchFromGitLab, buildNpmPackage, fetchNpmDeps, jq, moreutils, }: buildNpmPackage (finalAttrs: { pname = "glitchtip-frontend"; version = "5.1.1"; src = fetchFromGitLab { owner = "glitchtip"; repo = "glitchtip-frontend"; tag = "v${finalAttrs.version}"; hash = "sha256-WKh5w6AVyKhkGvGsy2Wv4Z01UaKTctDSfEhOek2Y84w="; }; npmDeps = fetchNpmDeps { inherit (finalAttrs) src; hash = "sha256-G2DZhHfTWi0qCAMs+IP7T2XEecBwTX12Dk3O0pD8ZJw="; }; postPatch = '' jq '.devDependencies |= del(.cypress, ."cypress-localstorage-commands")' package.json | sponge package.json ''; nativeBuildInputs = [ moreutils jq ]; buildPhase = '' runHook preBuild npm run build-prod runHook postBuild ''; installPhase = '' runHook preInstall cp -r dist/glitchtip-frontend/browser $out/ runHook postInstall ''; meta = { description = "Frontend for GlitchTip"; homepage = "https://glitchtip.com"; changelog = "https://gitlab.com/glitchtip/glitchtip-frontend/-/releases/v${finalAttrs.version}"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ defelo felbinger ]; }; })