5357 Commits

Author SHA1 Message Date
Matt Sturgeon
97046051a1 lib.customisation: fix typo in docs (#568696) 2026-10-02 00:25:31 +00:00
Ilan Joselevich
8405d4fce5 lib.meta.getDarwinApp{,'}: init (#539500) 2026-10-01 19:23:08 +00:00
David Wronek
a7b62128a1 lib.customisation: fix typo in docs
Signed-off-by: David Wronek <david.wronek@mainlining.org>
2026-09-30 17:04:17 +02:00
Ben Siraphob
07f0e5db55 treewide: replace reimplemented helpers with existing lib functions (#564688) 2026-09-30 12:16:02 +00:00
Eman Resu
3647d89269 lib.fixed-points.toExtension: inherit binding 2026-09-29 22:32:34 -04:00
Eman Resu
e64ec748f1 lib.fixed-points.composeExtensions: inline let variable
Only used once.
2026-09-29 22:30:47 -04:00
Eman Resu
7bd2aa7e08 lib.fixed-points.composeManyExtensions: beta reduce fold 2026-09-29 22:30:43 -04:00
nixpkgs-ci[bot]
362969a3a4 Merge master into staging-next 2026-09-28 00:28:27 +00:00
Jo
531062ef77 lib.licenses: drop gfl in favor of lppl13c (#557118) 2026-09-27 19:26:05 +00:00
nixpkgs-ci[bot]
5ec9cbdac1 Merge master into staging-next 2026-09-27 12:13:16 +00:00
Léana
199ee26b83 lib.modules: document mkOverride
Co-authored-by: Robert Hensing <roberth@users.noreply.github.com>
2026-09-27 12:30:55 +02:00
nixpkgs-ci[bot]
f2b3ac2ee7 Merge master into staging-next 2026-09-26 18:10:21 +00:00
Sefa Eyeoglu
d45fb8d4ac lib.licenses: expose mkLicense (#562287) 2026-09-26 15:59:22 +00:00
Jo
42c1626569 lib.licenses: improve doc-comments (#562286) 2026-09-26 15:44:02 +00:00
nixpkgs-ci[bot]
98fe6aa185 Merge master into staging-next 2026-09-25 06:16:15 +00:00
GraysonTinker
ac96b0d751 lib.lists: remove fold 2026-09-23 09:17:22 -06:00
Ethan Carter Edwards
2c2686cbbe lib.meta.getDarwinApp: init, add tests
This is useful for nix-darwin system.defaults.dock.persistent-apps

Signed-off-by: Ethan Carter Edwards <ethan@ethancedwards.com>
2026-09-20 17:17:38 -04:00
Ethan Carter Edwards
7246360b7d lib.meta.getDarwinApp': init, add tests
This is useful for nix-darwin system.defaults.dock.persistent-apps

Signed-off-by: Ethan Carter Edwards <ethan@ethancedwards.com>
2026-09-20 17:16:41 -04:00
Ben Siraphob
d3f13e3324 lib.attrsets: use lib.filterAttrs, lib.mapAttrs and lib.genAttrs 2026-09-18 11:59:44 -07:00
nixpkgs-ci[bot]
dd0a641804 Merge staging-next into staging 2026-09-18 00:24:51 +00:00
Samuel Ainsworth
17be3e0800 lib/fileset/internal.nix: introduce lib.lists.commonPrefixLength (#507639) 2026-09-17 21:52:01 +00:00
Randy Eckenrode
a9955997b6 lib.systems.elaborate: add Swift platform
Move the definition of the Swift arch, platform, and triple out of the
Swift compiler derivation; which should make it easier to handle
target-specific differences once Swift cross-compilation is supported.
2026-09-15 23:08:39 -04:00
Ryan Hendrickson
418b436480 lib.escapeShellArg: handle paths (#556219) 2026-09-15 17:03:22 +00:00
Robert Hensing
bc9263e560 lib.modules.mapAttrsOfSubmodule: init (#561282) 2026-09-14 23:33:23 +00:00
Robert Hensing
d773de213a types.path.check: Avoid derivation instantiation (#540399) 2026-09-13 17:03:09 +00:00
Robert Hensing
94072f9db5 lib/tests: make sure types.pathWith does not instantiate
See previous commit.
2026-09-13 18:56:27 +02:00
Eman Resu
20c3f1c345 lib/modules: fix typo (#560990) 2026-09-12 15:21:03 +00:00
jopejoe1
295b7d1805 lib.licenses: improve doc-comments
I was missing some understanding about the structure of doc-comments as 
I wrote these improved thes with a better understanding of how those get rendered.
2026-09-11 17:47:56 +02:00
jopejoe1
c392272b10 lib.licenses: expose mkLicense
make it so others can make use of it
2026-09-11 15:09:29 +02:00
Robert Hensing
4e28ca5700 lib.types.nullOr: implement v2 check & merge (#525519) 2026-09-11 12:15:55 +00:00
Ben Siraphob
54c3e474ef lib.modules: fix typo in deprecation warning 2026-09-09 13:12:24 -07:00
Johannes Kirschbauer
b631f949b9 lib.modules: small optimizations (#517881) 2026-09-09 13:34:10 +00:00
Robert Hensing
eab7314fbb lib.modules.mapAttrsOfSubmodule: edit doc 2026-09-09 08:47:21 +02:00
Robert Hensing
c70d9ffe53 lib.modules.mapAttrsOfSubmodule: init 2026-09-08 16:19:46 +02:00
HigherOrderLogic
47f57f573f lib/modules: fix typo 2026-09-07 19:04:28 +00:00
daimond113
a8cd7a2a1a doc/lib: show toSentenceCase's remainder lowering 2026-09-06 15:07:27 +00:00
Robert Hensing
78e15af140 lib/services: fix test expectations for the reload options (#545732) 2026-09-04 17:18:17 +00:00
Eman Resu
89a82e0ec7 lib.modules: avoid merging when type is already specified 2026-08-31 13:50:33 -04:00
Eman Resu
b8930be77c lib.modules: check res first when merging 2026-08-31 13:50:33 -04:00
Eman Resu
6a71bffb1b lib.modules: avoid logic if cfg has no _type attribute
Also move the check for `_type == "if` to be first, as in my
benchmarking, if statements occur far more often than merges (23k vs
3k).
2026-08-31 13:50:33 -04:00
Eman Resu
23c973c4c1 lib.modules: inline mapAttrsRecursiveCond call with more axioms
mapAttrsRecursiveCond generates an attribute path while iterating, but
we completely ignore it. We also don't need to run the isAttrs check,
since isOption will check if `v._type == "option"`, and ? runs a
typecheck internally. These combined justify the inlining in my opinion.
2026-08-31 13:50:32 -04:00
Eman Resu
91da5d6b41 lib.modules: avoid filtering disabled modules if they're empty 2026-08-31 13:50:32 -04:00
Eman Resu
47e958cd9a lib.modules: inline mergedType into a lower scope
This will only be used if `res ? type` (which is barely ever true, since
there's typically only ever one decl). We can avoid the thunk in every
case.
2026-08-31 13:50:32 -04:00
Eman Resu
aab4682e75 lib.modules: inline value variable in evalOptionValue 2026-08-31 13:50:31 -04:00
Eman Resu
be514e8dad lib.modules: beta reduce mergeOptionDecls for free 2026-08-31 13:50:31 -04:00
Eman Resu
2abe9edb0b lib.modules: inline several variables in definition merge 2026-08-31 13:50:30 -04:00
Eman Resu
93485d98a0 lib.modules: inline defns variable 2026-08-31 13:50:30 -04:00
Eman Resu
830dd996ea lib.modules: avoid filtering option decls in most cases 2026-08-31 13:50:28 -04:00
Eman Resu
d03c2169d2 lib.modules: inline warnDeprecation
Saves 0.5% of all thunks for my personal config.
2026-08-31 13:38:08 -04:00
Eman Resu
d3bbd01933 lib.modules: compute disabled module list early
isDisabled gets the list of disabledModules ready when it's only given
two attributes, so when it's passed the third argument, it just has to
call `elem` on its precomputed list. This was being used in the graph
right below, but now in module filtering.
2026-08-31 13:38:08 -04:00