nodejs_latest: 23.11.0 -> 24.0.0-rc.2

This commit is contained in:
Antoine du Hamel 2025-04-02 11:25:10 +02:00
parent d8e0934a9d
commit f1690c45b6
No known key found for this signature in database
GPG key ID: 21D900FFDB233756
6 changed files with 18 additions and 14 deletions

View file

@ -185,6 +185,8 @@
- `mkBinaryCache` now defaults to using `zstd` compression for the binary caches it creates. The previous `xz` compression method can be used by passing `compression = "xz";`.
- `nodejs_latest` was updated from 23.x to 24.x. `nodejs_23` has been removed in favor of `nodejs_24`.
- `nodePackages."@commitlint/config-conventional"` has been removed, as it is a library, and projects should depend on it instead.
- zigbee2mqtt is now available in version 2.x as `zigbee2mqtt_2`. In NixOS 25.11 we'll remove `zigbee2mqtt_1` and default to `zigbee2mqtt_2`. See the [breaking changes](https://github.com/Koenkk/zigbee2mqtt/discussions/24198) announcement for 2.0.0.

View file

@ -2,7 +2,7 @@
lib,
stdenv,
fetchFromGitHub,
nodejs_23,
nodejs_latest,
pnpm_9,
cacert,
}:
@ -33,12 +33,12 @@ stdenv.mkDerivation (finalAttrs: {
};
nativeBuildInputs = [
nodejs_23
nodejs_latest
pnpm_9.configHook
];
buildInputs = [
nodejs_23
nodejs_latest
];
pnpmWorkspaces = [ "@tailwindcss/language-server..." ];

View file

@ -1,6 +1,6 @@
#!/usr/bin/env nix-shell
/*
#!nix-shell -i node --pure --packages cacert nodejs_23
#!nix-shell -i node --pure --packages cacert nodejs_latest
*/
import * as assert from "node:assert/strict";
import * as fsPromises from "node:fs/promises";

View file

@ -176,6 +176,8 @@ let
done
'';
downloadDir = if lib.strings.hasInfix "-rc." version then "download/rc" else "dist";
package = stdenv.mkDerivation (
finalAttrs:
let
@ -188,7 +190,7 @@ let
inherit pname version;
src = fetchurl {
url = "https://nodejs.org/dist/v${version}/node-v${version}.tar.xz";
url = "https://nodejs.org/${downloadDir}/v${version}/node-v${version}.tar.xz";
inherit sha256;
};
@ -519,7 +521,7 @@ let
passthru.tests = {
version = testers.testVersion {
package = self;
version = "v${version}";
version = "v${lib.head (lib.strings.splitString "-rc." version)}";
};
};

View file

@ -17,8 +17,8 @@ let
in
buildNodejs {
inherit enableNpm;
version = "23.11.0";
sha256 = "f2c5db21fc5d3c3d78c7e8823bff770cef0da8078c3b5ac4fa6d17d5a41be99d";
version = "24.0.0-rc.2";
sha256 = "729fca42bb7266031dd020f3935423ea8d4b4e2d119b34b608f1d079e5c1621a";
patches =
(
if (stdenv.hostPlatform.emulatorAvailable buildPackages) then

View file

@ -4209,14 +4209,14 @@ with pkgs;
nodejs-slim_22 = callPackage ../development/web/nodejs/v22.nix { enableNpm = false; };
corepack_22 = hiPrio (callPackage ../development/web/nodejs/corepack.nix { nodejs = nodejs_22; });
nodejs_23 = callPackage ../development/web/nodejs/v23.nix { };
nodejs-slim_23 = callPackage ../development/web/nodejs/v23.nix { enableNpm = false; };
corepack_23 = hiPrio (callPackage ../development/web/nodejs/corepack.nix { nodejs = nodejs_23; });
nodejs_24 = callPackage ../development/web/nodejs/v24.nix { };
nodejs-slim_24 = callPackage ../development/web/nodejs/v24.nix { enableNpm = false; };
corepack_24 = hiPrio (callPackage ../development/web/nodejs/corepack.nix { nodejs = nodejs_24; });
# Update this when adding the newest nodejs major version!
nodejs_latest = nodejs_23;
nodejs-slim_latest = nodejs-slim_23;
corepack_latest = hiPrio corepack_23;
nodejs_latest = nodejs_24;
nodejs-slim_latest = nodejs-slim_24;
corepack_latest = hiPrio corepack_24;
buildNpmPackage = callPackage ../build-support/node/build-npm-package { };