build(notices): third-party licence notices, generated and checked
Every licence the program's dependencies and bundled fonts carry (MIT, Apache-2.0, BSD, ISC, Zlib, the SIL Open Font License) asks that its copyright notice and licence text travel with each copy of the binary, and until now nothing shipped them. `just notices` (scripts/notices.sh) writes THIRD-PARTY-NOTICES.txt: cargo-about names every crate the `wanderbooks` binary links, from ledger-cli's manifest across every feature and platform the program ships on, with the licence text; the script then adds the embedded fonts and their licence files. `just notices-check`, in the lint part of `just check`, regenerates the file and fails when a dependency or font changed without it, so the committed copy cannot drift. cargo-about is a build tool used to generate and check the file; it is not a dependency of the program (no Cargo.toml or Cargo.lock changes). Its accepted list is deny.toml's allow list word for word. Co-Authored-By: DeepSeek V4.1 Flash
This commit is contained in:
1 parent
1726c8b6dd
commit
7f87ccd3d3
6 files changed
+12524
No files matched your search
@@ -39,6 +39,7 @@ check-shard shard:
|
||||
just server-only
|
||||
just check-shards-agree
|
||||
just deny
|
||||
just notices-check
|
||||
;;
|
||||
# The viewer's tests are half of the suite's time, in two halves
|
||||
# of their own: its unit tests, and its integration tests. Between
|
||||
@@ -66,6 +67,18 @@ check-shard shard:
|
||||
deny:
|
||||
cargo deny check
|
||||
|
||||
# The third-party notices every licence asks to travel with
|
||||
# (THIRD-PARTY-NOTICES.txt): each crate the `wanderbooks` binary links and
|
||||
# its licence text, then the fonts embedded, each with its licence. Writes
|
||||
# the file; commit it.
|
||||
notices:
|
||||
scripts/notices.sh
|
||||
|
||||
# Whether THIRD-PARTY-NOTICES.txt still matches the dependencies: a crate
|
||||
# added, removed or upgraded without regenerating it fails (`just notices`).
|
||||
notices-check:
|
||||
scripts/notices.sh --check
|
||||
|
||||
# CI's list of parts is this file's: a part CI never runs is a check
|
||||
# nobody makes, and a part only CI names fails there, not here.
|
||||
check-shards-agree:
|
||||
|
||||
Reference in new issue
Block a user