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
18 lines
302 B
Nix
18 lines
302 B
Nix
{
|
|
buildDunePackage,
|
|
js_of_ocaml-compiler,
|
|
ppxlib,
|
|
}:
|
|
|
|
buildDunePackage {
|
|
pname = "js_of_ocaml";
|
|
|
|
inherit (js_of_ocaml-compiler) version src;
|
|
|
|
buildInputs = [ ppxlib ];
|
|
|
|
propagatedBuildInputs = [ js_of_ocaml-compiler ];
|
|
|
|
meta = removeAttrs js_of_ocaml-compiler.meta [ "mainProgram" ];
|
|
}
|