Repository navigation
fix: ship LICENSE-MIT, LICENSE-APACHE and NOTICE.md in every published crate - #88
Merged
Merged
Conversation
…d crate All ten published crates (rusty_xml, -parser, -tree, -sax, -reader, -writer, -xpath, -valid, -cli, -alloc) declare `MIT OR Apache-2.0`, but `cargo package --list` showed no licence text in any of them: the files live only at the workspace root, and cargo packages a crate's own directory. Copy the root texts (holder "Mata Network") and the NOTICE into each published crate's directory. CI: the package job now checks, for every package whose `publish` is not false, that the copies are identical to the root files and that `cargo package --list` includes them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The workspace declares
license = "MIT OR Apache-2.0"for all ten published crates, but none of their packages contains a licence text.cargo package --listonmain(0.10.4), for each ofrusty_xml,rusty_xml-parser,-tree,-sax,-reader,-writer,-xpath,-valid,-cli,-alloc:LICENSE-MIT,LICENSE-APACHEandNOTICE.mdexist only at the workspace root. Cargo packages a crate's own directory and cannot pull in files from outside it, so the published tarballs have been shipping without them. (rusty_xml-c-abiandrusty_xml-bencharepublish = falseand are not affected.)Fix
LICENSE-MIT(MIT, "Copyright (c) 2026 Mata Network"),LICENSE-APACHE(Apache-2.0, appendix "Copyright 2026 Mata Network") andNOTICE.mdinto each published crate's directory. They are byte-identical to the root files. The NOTICE is included because Apache-2.0 §4(d) expects it to travel with the work, and it carries the libxml2 attribution.include, andrusty_xml'sexclude = ["tests"]does not touch these files.After the change, each of the ten packages lists:
Guard
The
packageCI job gets a new step. For every workspace package whosepublishis not false, it checks that the three copies are identical to the root files (diff -u) and thatcargo package --listincludes them. A new crate added without the files, or a root licence edit that doesn't reach the copies, fails CI.Not released. The next release-plz release will carry the files.
🤖 Generated with Claude Code