reuse-tool
reuse-tool copied to clipboard
CLI usability and documentation
I just got started with reuse and found, what I think is, potential for improving the workflow. Ideally, I'd like to work like this:
reuse init(ask me helpful questions, create theLICENSES/folder and default configuration.reuse/.dep5)reuse lint(tell me what needs to be done!)reuse config(extend default configuration, e.g. add file patterns to.reuse/.dep5)reuse apply(add or update licenses on all files matching the configured patterns)reuse lint(tell me if I'm all good now; go to step 3 if not)- Optionally,
reuse addheader(only if there is really just a single file or an exception to the configured rules)
Docs (usage, tutorial)
The docs aren't streamlined yet to suggest such a workflow, at least not in a similar concise fashion.
The documentation and especially the tutorial are very nice, but they both appear to favor adding license information manually. The Tool instructions for this step + boxes suggest that the tutorial's primary idea is to educate about licensing whereas developers (like me) are probably mainly interested in getting the problem fixed with the tool.
How use the config? (file patterns + licenses)
What is confusing for me as a beginner is that adding file patterns that should be covered by a specific license is encouraged, but there doesn't seem to be a way to use that configuration (e.g. with addheader). Hence my suggestion above about reuse apply.
Finally, I found it irritating that I can (or "need to") configure licenses for the project, but then I have to spell them out in their entirety with the addheader command. What would be helpful:
- Default behavior and fallbacks (e.g. no need to specify
--copyrightor--licensewhen only a single license is configured) - A simple + safe way to select a license (e.g. case-insensitive
startswithon configured licenses, rejection of not-configured ones)
Potentially related
- #68
- #158