I went through the NixOS 25.11 release notes and picked some of the changes that I found particularly interesting. 🧵

#NixOS #nixpkgs

Some very useful options have been added to nixpkgs config:

nixpkgs.config.rewriteURL: Allows rewriting URLS downloaded by fetchurl, to configure company-internal mirrors, or work around company firewalls and similar networking restrictions.

nixpkgs.config.hashedMirrors: Allows setting content-addressed mirrors that fetchurl can fallback to if the primary URL is unavailable.

nixpkgs.config.{gitConfig, gitConfigFile}: Configures the default git config used by fetchgit. Can be used to point to local mirrors.

nixpkgs.config.npmRegistryOverrides: Configures NPM registry overrides for fetchNpmDeps.

fetchgit gained two new arguments: gitConfigFile to set a git config for an individual derivation, and rootDir to limit the resulting source to a subdirectory of the Git repository.

#NixOS #nixpkgs

This breaking change took me by surprise: Previously, there was a clear contract in nixpkgs that changes to the meta attribute of a packages wouldn't trigger a rebuild of the package itself. Changing meta.mainProgram could trigger rebuilds in downstream packages that used lib.getExe, but that was it.

With this version of NixOS, meta.mainProgram is exposed as environment variable NIX_MAIN_PROGRAM to the build environment. You should check downstream and remove existing overrides of meta.mainProgram, as these will trigger a rebuild of the package (and all its dependents) now.

#NixOS #nixpkgs

@katexochen
Wait what? Who did that, why?
@katexochen Ty! Already gone through :Git blame