Commit Graph

8 Commits

Author SHA1 Message Date
Sam Morrow adaa6a1d86 fix: use LC_ALL=C for consistent sorting across systems
The sort command uses locale-specific ordering which can differ between
systems. Use LC_ALL=C to ensure consistent ordering in CI and locally.
2025-12-12 16:36:59 +01:00
Sam Morrow e7e2925666 fix: update licenses-check to use new architecture-aware format
- Check now regenerates using ./script/licenses and compares
- Add GOROOT/PATH setup in CI to fix go-licenses module info errors
- Check both license files AND third-party directory for changes
- See: https://github.com/google/go-licenses/issues/244
2025-12-12 16:36:59 +01:00
Sam Morrow 3a1844c22c fix: make license script portable and deterministic
Address review feedback:
- Remove bash 4.0+ associative array requirement for macOS compatibility
- Add cross-platform hash function (md5sum on Linux, md5 on macOS)
- Ensure deterministic iteration order using sorted groups file
- Add better error handling for failed go-licenses commands
- Fix grammar: 'architecture(s)' -> 'architectures'
- Add documentation for third-party/ being a union of all architectures
- Use file-based state instead of associative arrays for portability
2025-12-12 16:36:59 +01:00
Sam Morrow 87ea319ee1 fix: handle architecture-specific license differences
The licenses script now:
- Generates separate license reports per GOOS/GOARCH combination
- Groups identical reports together (comma-separated arch names)
- Adds a Table of Contents at the top of each platform file
- Handles cases where different architectures have different dependencies
  (e.g., x/sys/unix vs x/sys/windows, mousetrap on Windows only)

This addresses the issue discovered in cli/cli where some deps changed
which changed the mod graph for different GOARCH and affected the
exported licenses because go-licenses tries to find common ancestors.
2025-12-12 16:36:59 +01:00
JoannaaKL 6a39a39e6d Add html filtering (#1356)
* Add html content sanitizer

* Add basic html sanitization

* .

* Correct licenses and scripts to ignore vendor directory

* Use singleton

* Simplify
2025-11-05 12:49:49 +01:00
Sangmin Lee 9a40fd8e62 fix: correct spelling of 'license' 2025-04-08 01:19:02 +02:00
Sam Morrow 26f96680a9 chore: support x-platform licence generation (#98) 2025-04-04 15:33:36 +02:00
Sam Morrow 450fa651a6 add oss licenses 2025-04-01 18:17:52 +02:00