mempool: 3.3.2
- Node 26, en-US-only frontend build - Set NG_FORCE_TTY=false: under Nix's pty the Angular CLI spinner redraws forever and the frontend build never finishes - generate.sh: verify release tags against pinned wiz or mononaut fingerprints (mononaut signs since v3.3.0; key fetched from GitHub) - Newer mining-pool logos - nginx: serve the English site at / instead of redirecting - docs/fork-maintenance.md: reflect 3.3.2, Node 26 and the signer change Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
{ lib
|
||||
, stdenvNoCC
|
||||
, nodejs_22
|
||||
, nodejs-slim_22
|
||||
, nodejs_26
|
||||
, nodejs-slim_26
|
||||
, fetchFromGitHub
|
||||
, fetchNodeModules
|
||||
, runCommand
|
||||
@@ -16,34 +16,34 @@
|
||||
, napi-rs-cli
|
||||
}:
|
||||
rec {
|
||||
nodejs = nodejs_22;
|
||||
nodejsRuntime = nodejs-slim_22;
|
||||
nodejs = nodejs_26;
|
||||
nodejsRuntime = nodejs-slim_26;
|
||||
|
||||
version = "3.2.1";
|
||||
version = "3.3.2";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "mempool";
|
||||
repo = "mempool";
|
||||
tag = "v${version}";
|
||||
hash = "sha256-O2XPD1/BXQnzuOP/vMVyRfmFZEgjA85r+PShWne0vqU=";
|
||||
hash = "sha256-xMMBr3bSOwVNgpjOPVf7MEcGvhhNneTsE8PH9sLUr30=";
|
||||
};
|
||||
|
||||
nodeModules = {
|
||||
frontend = fetchNodeModules {
|
||||
inherit src nodejs;
|
||||
sourceRoot = "source/frontend";
|
||||
hash = "sha256-+jfgsAkDdYvgso8uSHaBj/sQL3fC/ABQWzVTXfdZcU0=";
|
||||
hash = "sha256-LRK2W5Ypml5QSTWTHtUpilDXm5gIt13wL0pGBgkhhvk=";
|
||||
};
|
||||
backend = fetchNodeModules {
|
||||
inherit src nodejs;
|
||||
sourceRoot = "source/backend";
|
||||
hash = "sha256-y5l2SYZYK9SKSy6g0+mtTWD6JFkkdQHHBboECpEvWZ4=";
|
||||
hash = "sha256-jszxFq1+H9D0p0NNB6q0iFoVy2gLAmdlnzPDK8ywJo0=";
|
||||
};
|
||||
};
|
||||
|
||||
frontendAssets = fetchFiles {
|
||||
name = "mempool-frontend-assets";
|
||||
hash = "sha256-r6GfOY8Pdh15o2OQMk8syfvWMV6WMCReToAEkQm7tqQ=";
|
||||
hash = "sha256-hnW3VUTFgrQyDWizdxYaX6Vf2m/+RYp1x2cWCg+8HM0=";
|
||||
fetcher = ./frontend-assets-fetch.sh;
|
||||
};
|
||||
|
||||
@@ -99,6 +99,23 @@ rec {
|
||||
# internet. Disable this script and instead add the assets manually after building.
|
||||
: > sync-assets.js
|
||||
|
||||
# Only build the en-US locale instead of all ~30 translations.
|
||||
# This greatly reduces build time. The output layout (`<locale>/index.html`)
|
||||
# is unchanged, and nginx falls back to `en-US` for all other languages.
|
||||
substituteInPlace package.json --replace-fail 'production --localize' 'production'
|
||||
node -e '
|
||||
const fs = require("fs");
|
||||
const f = "angular.json";
|
||||
const a = JSON.parse(fs.readFileSync(f));
|
||||
a.projects.mempool.architect.build.options.localize = ["en-US"];
|
||||
fs.writeFileSync(f, JSON.stringify(a, null, 2));
|
||||
'
|
||||
|
||||
# The Nix builder's stdout is a pty, so the Angular CLI enables its interactive
|
||||
# progress spinners. These redraw endlessly (gigabytes of escape codes) and
|
||||
# stall the build. Disable TTY detection.
|
||||
export NG_FORCE_TTY=false
|
||||
|
||||
${lib.optionalString (config != {}) ''
|
||||
ln -s ${builtins.toFile "mempool-frontend-config" (builtins.toJSON config)} mempool-frontend-config.json
|
||||
''}
|
||||
|
||||
Reference in New Issue
Block a user