feat: show third-party licenses in About and generate aggregated license file #2
Workflow file for this run
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
| name: licenses-drift-guard | |
| # THIRD_PARTY_LICENSES.md is generated from the resolved dependencies | |
| # (tool/generate_licenses.dart). This fails the PR if it drifts out of sync, | |
| # i.e. dependencies changed but the file was not regenerated and committed. | |
| on: | |
| pull_request: | |
| branches: | |
| - develop | |
| permissions: | |
| contents: read | |
| jobs: | |
| verify: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: subosito/flutter-action@v2 | |
| with: | |
| flutter-version: 3.44.0 | |
| cache: true | |
| - name: Resolve dependencies | |
| run: flutter pub get | |
| - name: Regenerate third-party licenses | |
| run: dart run tool/generate_licenses.dart --strict | |
| - name: Verify THIRD_PARTY_LICENSES.md is up to date | |
| run: | | |
| if ! git diff --exit-code -- THIRD_PARTY_LICENSES.md; then | |
| echo "::error::THIRD_PARTY_LICENSES.md is out of date. Run 'melos run licenses:generate' and commit the result." | |
| exit 1 | |
| fi | |
| echo "OK: THIRD_PARTY_LICENSES.md is up to date." |