Commit Graph

4744 Commits

Author SHA1 Message Date
Philip Taron
21623b7ce7 Reapply "splice.nix: make pkgs splicedPackages" (#456138) 2025-11-01 13:49:33 +00:00
Robert Hensing
acb6191c6e lib: Add splicing utilities (#426889) 2025-10-30 21:22:54 +00:00
Wolfgang Walther
4949737a38 systems/examples: remove x86_64-unknown-redox
relibc itself has been removed in 2024 already.
2025-10-28 21:54:04 +01:00
Robert Hensing
586961172a lib/modules: Report error for unsupported t // { check = ...; } (#454964) 2025-10-28 16:40:39 +00:00
Silvan Mosberger
7636389851 lib.teams: Add githubId from associated github teams
This will allow the code for https://github.com/NixOS/nixpkgs/issues/447514
to make sure that the right team is requested for review,
even if it has been renamed in the meantime.

While the matching is currently based on the teams slug/name and not the
id, renames won't cause problems with `lib.teams`, because CI would
error if there's no match. Changing this can be future work.
2025-10-28 00:01:51 +01:00
Silvan Mosberger
ddf8b5da4a lib.teams: Add githubMaintainers field
This is so you can figure out who to ask to get added to the team

Also avoid an unecessary `{ inherit lib; }` argument
2025-10-27 19:36:58 +01:00
Silvan Mosberger
428bd8f1a2 lib.teams: Populate fields from synced GitHub state
The before and after of

    nix-instantiate --eval -A lib.teams --strict --json | jq 'walk(if type == "array" then sort else . end)'

has been ensured to be negligible, only consisting of minor team
shortName and scope differences
2025-10-27 19:36:57 +01:00
Johannes Kirschbauer
8c222f2fc7 treewide: remove deprecated lib functions that had warning for more than 2 years (#454377) 2025-10-25 20:35:54 +00:00
Alyssa Ross
d563aa57de lib.systems.parse: Default glibc ppc64 to ELFv1 ABI (#451088) 2025-10-25 09:57:43 +00:00
Alyssa Ross
9711c5ae0d lib.systems: Simplify ABI on POWER for rust.rustcTarget (#451087) 2025-10-25 09:57:09 +00:00
Aliaksandr
dc7095a86e treewide: remove deprecated lib functions that had warning for more than 2 years 2025-10-24 06:30:16 +03:00
Robert Hensing
93ea59f66d lib/modules: Report error for unsupported // { check }
`check` can have a new place since the introduction of
merge.v2. This makes the // { check = ... } idiom unreliable.

In this PR we add checks to detect and report this.

merge.v2 introduced in:
https://github.com/NixOS/nixpkgs/pull/391544

Real world case:
https://hercules-ci.com/github/hercules-ci/hercules-ci-effects/jobs/875
2025-10-23 19:06:05 +02:00
Wolfgang Walther
3e505de718 freeimage: drop
Very insecure.
2025-10-23 13:54:39 +02:00
Johannes Kirschbauer
43b77e1457 lib/cli: add toCommandLine (#404233) 2025-10-22 14:45:00 +00:00
Philip Taron
62d9b8a326 lib.customisation: fix error message when running in nix repl (#452573) 2025-10-22 02:06:47 +00:00
Silvan Mosberger
a8ae0941a3 lib/types: small typo fix (#454354) 2025-10-21 22:31:12 +00:00
Aliaksandr
bb56489b2f lib/types: small typo fix 2025-10-22 00:20:17 +03:00
Lukas Wurzinger
1f4c50ab81 lib/cli: deprecate toGNUCommandLine 2025-10-21 21:01:38 +02:00
Lukas Wurzinger
73e8a483e6 lib/cli: add toCommandLine 2025-10-21 21:01:32 +02:00
Aliaksandr
def801fb09 lib: deprecate mkAliasOptionModuleMD 2025-10-21 16:00:52 +03:00
nixpkgs-ci[bot]
fe3676c810 Merge master into staging-next 2025-10-18 06:05:29 +00:00
Connor Baker
4617867f58 intel-oneapi.{base,hpc}: init at 2025.2.1.44 (#448561) 2025-10-18 02:50:21 +00:00
Jeremy Fleischman
775ce27666 lib.customisation: fix error message when running in nix repl
This code was more careful before
<dd435697b3>
(it didn't assume that `unsafeGetAttrPos` always returns a non-null
location). Unfortunately, `unsafeGetAttrPos` *does* return `null` when
dealing with `nix repl`:

```
nix-repl> f = {foo}: foo

nix-repl> builtins.unsafeGetAttrPos "foo" (builtins.functionArgs f)
null
```

Here's how to reproduce the issue.

*Before* this fix:

```
nix-repl> f = {foo}: foo

nix-repl> myCallPackage = lib.callPackageWith {}

nix-repl> myCallPackage f {}
error:
       … while calling the 'abort' builtin
         at /home/jeremy/src/github.com/NixOS/nixpkgs/lib/customisation.nix:323:7:
          322|     else
          323|       abort "lib.customisation.callPackageWith: ${error}";
             |       ^
          324|

       … while selecting an attribute
         at /home/jeremy/src/github.com/NixOS/nixpkgs/lib/customisation.nix:310:14:
          309|         "Function called without required argument \"${arg}\" at "
          310|         + "${loc.file}:${toString loc.line}${prettySuggestions (getSuggestions arg)}";
             |              ^
          311|

       error: expected a set but found null: null

```

*After*:

```
nix-repl> f = {foo}: foo

nix-repl> myCallPackage = lib.callPackageWith {}

nix-repl> myCallPackage f {}
error:
       … while calling the 'abort' builtin
         at /home/jeremy/src/github.com/NixOS/nixpkgs/lib/customisation.nix:332:7:
          331|     # Inputs
          332|
             |       ^
          333|     `autoArgs`

       error: evaluation aborted with the following error message: 'lib.customisation.callPackageWith: Function called without required argument "foo" at <unknown location>'
```
2025-10-16 08:27:01 -04:00
nixpkgs-ci[bot]
f5c2101b71 Merge master into staging-next 2025-10-13 18:05:26 +00:00
Philip Taron
3aefc14aca lib.attrsets: remove deprecated names
- `lib.attrsets.cartesianProductOfSets` was deprecated in 228621e42d
- `lib.attrsets.zip` was deprecated in fcbc4fe9ff (2013!)
- `lib.attrsets.zipWithNames` was deprecated in 00127bef3f (2009!)

The time has come.
2025-10-13 09:09:59 -07:00
Philip Taron
3050865cc3 lib: remove mapAttrsFlatten after a year (#450420) 2025-10-13 16:00:11 +00:00
Philip Taron
db45f2b770 lib: remove mapAttrsFlatten after a year
It was deprecated in b9c51260d0.
2025-10-13 08:55:22 -07:00
Philip Taron
59fe6e0c5f lib.filesystem: remove Nix 2.14 shim (#450408) 2025-10-13 15:51:27 +00:00
OPNA2608
37492033eb lib.systems.parse: Default glibc ppc64 to ELFv1 ABI 2025-10-11 21:00:33 +02:00
OPNA2608
8448c28919 lib.systems.examples.ppc64-elfv1: Drop manual fix of rust.rustcTarget
ABI is now simplified automatically.
2025-10-11 20:57:29 +02:00
OPNA2608
8b06bf875c lib.systems: Simplify ABI on POWER for rust.rustcTarget
Rust does not know how to parse "gnuabielfv{1,2}", so simplify those down to just "gnu".
This obsoletes the manual rustcTarget fix in the ppc64-elfv1 example.
2025-10-11 20:48:52 +02:00
nixpkgs-ci[bot]
7e9e7583ef Merge master into staging-next 2025-10-10 00:16:30 +00:00
Philip Taron
1677539966 lib.lists: undeprecate crossLists (#393573) 2025-10-09 22:19:57 +00:00
Luna Nova
d1de5d4748 lib.lists: undeprecate crossLists
mapCartesianProduct's output's order relies on the iteration order of the input attrset
encouraging picking non-meaningful names or arbitrary prefixed underscores if your usecase
requires a specific order.

See this thread for examples of clunkiness required to achieve a specific ordering.
https://discourse.nixos.org/t/lib-crosslists-is-deprecated-use-lib-cartesianproductofsets-instead/41824/10
2025-10-09 14:58:51 -07:00
Philip Taron
4f652cfaf4 lib.filesystem: remove Nix 2.14 shim
It was added in fcaa2b1097. Lix is based off of 2.18, and the minimum version for Nixpkgs has long since incorporated this builtin.
2025-10-09 12:23:38 -07:00
nixpkgs-ci[bot]
b64b1a6e98 Merge master into staging-next 2025-10-09 18:06:05 +00:00
Philip Taron
b364a40a6b lib.filesystem.listFilesRecursive: only flatten once (#449744) 2025-10-09 17:19:48 +00:00
nixpkgs-ci[bot]
0d76c40190 Merge master into staging-next 2025-10-09 12:07:04 +00:00
Silvan Mosberger
1ea51e1f1a lib.teams: Remove .githubTeams in favor of singular .github
No team was using the feature of having multiple GitHub teams, and this
would make it tricky to try to sync maintainer teams with GitHub teams.
2025-10-08 21:44:39 +02:00
Eman Resu
ca59048a42 lib.filesystem.listFilesRecursive: only flatten once 2025-10-07 21:12:46 -04:00
nixpkgs-ci[bot]
bd43b58711 Merge master into staging-next 2025-10-08 00:16:11 +00:00
dish
92aa5dc190 lib: remove lib.options.mkPackageOptionMD
Removed this, as it was deprecated in 24.11 and was intended to be
removed in 25.05. Better late than never.
2025-10-07 15:53:30 -04:00
K900
fb73ccd10d Merge remote-tracking branch 'origin/staging-next' into staging 2025-10-07 08:19:36 +03:00
Johannes Kirschbauer
bb9da33c62 lib/*: fix docs to use "returns" instead of "return" (#442388) 2025-10-06 08:09:54 +00:00
Wolfgang Walther
5e1f5b623b Merge branch 'staging-next' into staging 2025-10-05 11:40:56 +02:00
K900
e93c560b79 Merge remote-tracking branch 'origin/master' into staging-next 2025-10-05 12:17:08 +03:00
Wolfgang Walther
91a8fee3aa treewide: remove redundant parentheses
Auto-fixed by nixf-diagnose.
2025-10-05 10:52:03 +02:00
Alexander Bantyev
66e2080e23 intel-oneapi.{base,hpc}: init at 2025.2.1.44
Introduces the two freeware Intel's OneApi toolkits.

The Intel® oneAPI Base Toolkit (Base Kit) is a core set of tools and
libraries for developing high-performance, data-centric applications
across diverse architectures. It features an industry-leading C++
compiler that implements SYCL*, an evolution of C++ for heterogeneous
computing.

Intel® oneAPI HPC Toolkit delivers what developers need to build,
analyze, optimize, and scale HPC (high-performance computing)
applications with the latest techniques in vectorization,
multithreading, multi-node parallelization, and memory optimization.

They are packaged from official "offline" installers, which require
some wrangling to get working due to their reliance on FHS. The
resulting libraries and tools seem to work fine without FHS.
2025-10-04 20:24:10 +04:00
dramforever
736ac3f69f Merge remote-tracking branch 'nixos/staging-next' into HEAD 2025-10-04 22:46:07 +08:00
nixpkgs-ci[bot]
45e7932c78 Merge master into staging-next 2025-10-04 12:05:54 +00:00