pkgs: remove optional builtins prefixes from prelude functions#447404
Conversation
|
There are a couple minor regressions (not in this PR, in the tree) around changes that #301014 introduced. Anything that uses |
8a20a1a to
07c0849
Compare
Off topic, I know, but I thought we'd done treewides in the past to wrap such Also: did the issues with |
Great catch! I reverted this in the new commit "lixPackageSets.git: revert removal of builtins prefixes in patch".
Should this PR target the For reference, this PR is marked as draft according to #447402 (comment). |
No, this PR had <100 rebuilds so master is fine (it now only has 4). It was just worth mentioning that what should be a no-op refactor had any rebuilds at all. |
|
I took a look at each file and rebuild. This is good to check in once the merge conflict (trivial) is resolved. I would resolve it myself but that would break @trueNAHO's commit signing. |
Remove optional builtins prefixes from prelude functions by running:
builtins=(
abort
baseNameOf
break
derivation
derivationStrict
dirOf
false
fetchGit
fetchMercurial
fetchTarball
fetchTree
fromTOML
import
isNull
map
null
placeholder
removeAttrs
scopedImport
throw
toString
true
)
fd \
--type file \
. \
pkgs \
--exec-batch sed --in-place --regexp-extended "
s/\<builtins\.($(
printf '%s\n' "${builtins[@]}" |
paste --delimiter '|' --serial -
))\>/\1/g
"
nix fmt
07c0849 to
8052c76
Compare
Thanks :)
Done. |
Establish the builtins prefix convention for prelude attributes to
progress [1] ("Unwritten style guides should be written"), following the
treewide removal of the builtins prefix for prelude attributes [2] [3]
[4] [5] [6].
[1]: NixOS#387072
[2]: NixOS#444432
[3]: NixOS#447401
[4]: NixOS#447402
[5]: NixOS#447403
[6]: NixOS#447404
Related PRs intentionally split up to simplify review and merging:
Things done
passthru.tests.nixpkgs-reviewon this PR. See nixpkgs-review usage../result/bin/.Add a 👍 reaction to pull requests you find important.