Per-file license notes in Nixpkgs

Dear Nixpkgs maintainers,

in the context of this year’s Summer of Nix efforts around a new monorepo for software projects funded through NGI we’re yet to choose an appropriate license. Our project leads at NLnet would prefer (weak) copyleft to ensure that public money keeps translating into public code, and one option to enable that would be MPL 2.0.

Now of course we want anyone to pick up the program participants’ work and upstream it to Nixpkgs for broader visibility and ongoing maintenance. With MPL that would require a per-file copyright notice, possibly in the form recommended by REUSE. While this is something we could easily implement for NGIpkgs itself, it may not be welcome in Nixpkgs.

What do you think? Would that work out? Alternatively, do you have suggestions apart from licensing under MIT?

Thanks for your help!

2 Likes

Since there was no feedback and I’m inclined to favor the practical side of things, which is easing migration into Nixpkgs, here’s the PR to apply MIT: add MIT license by fricklerhandwerk · Pull Request #95 · ngi-nix/ngipkgs · GitHub

I’m a big copyleft advocate, but I don’t think it’s feasible to have Nix expressions in Nixpkgs with different licenses.

Even with MIT, it’s not seamless to include external code into Nixpkgs, because of MIT’s requirement to preserve copyright notices. It’s not clear where copyright notices other than the ones already in Nixpkgs’ COPYING file should go — it has to be somewhere that it’s clear to people copying that code out of Nixpkgs that they have to maintain it as well.

For this reason, I’ve licensed Nix code in my recent projects under the MIT-0 license, which is MIT with that requirement removed. IMO, Nix code outside of Nixpkgs is rarely substantial enough for attribution to be important anyway. (If it is, it probably means Nixpkgs is missing some code to make it easier.)

3 Likes