What is Nixpkgs preferred programming language?

quickjs could be good choices, since

  • Its tarballs are as small as those of jq;
  • It has simple interfaces with the OS;
  • JavaScript tutorials, tools and examples are everywhere, and thus I guess (if it is allowed) the LLM generated code for JS be among the most ready-for-production ones; Sorry I forgot that LLM is not allowed for contributions.
  • Unlike other tool/toy languages, JavaScript is standardized as ECMA-262, so version changes can’t break the existing code;
  • What else handles JavaScript Object Notation more natively than JavaScript?
  • There are even many languages compiled to JS to eliminate its defeats, so it won’t be too big a problem if someone (like me!) hates its syntax and/or semantics.

However, the builtin std and os modules of quickjs are too simple and rough to be used for scripting. So if Nixpkgs accepts it as an official scripting language, some additional utilities must be provided, just like those Bash functions.

1 Like