nix-init icon indicating copy to clipboard operation
nix-init copied to clipboard

License not found if located in LICENSES folder (REUSE compliance)

Open bittner opened this issue 1 month ago • 0 comments

I just tried nix-init on a Python project, and it works well except for the license detection.

Problem

When the project contains license(s) in a LICENSES folder nix-init is unable to find it.

Example

The pyclean project is a REUSE-compliant project.

The meta block created by nix-init looks like this:

  meta = {
    description = "Pure Python cross-platform pyclean. Clean up your Python bytecode";
    homepage = "https://github.com/bittner/pyclean";
    license = lib.licenses.unfree; # FIXME: nix-init did not find a license
    maintainers = with lib.maintainers; [ ];
    mainProgram = "pyclean";
  };

Background

The REUSE specification says:

Each License File MUST be placed in the LICENSES/ directory in the root of the Project.

When you run the reuse tool over your code base a LICENSES folder will be created and your project's license(s) are deposited there.

bittner avatar Oct 14 '25 10:10 bittner