Skip to content

Merge pull request #1293 from AChep/dependabot/gradle/ktor-3.4.1 #1005

Merge pull request #1293 from AChep/dependabot/gradle/ktor-3.4.1

Merge pull request #1293 from AChep/dependabot/gradle/ktor-3.4.1 #1005

name: "✔️ Check Licenses"
on:
workflow_dispatch:
push:
branches:
- master
paths:
- '**/*.gradle*'
- 'gradle/**'
pull_request:
branches:
- master
paths:
- '**/*.gradle*'
- 'gradle/**'
jobs:
check-licenses:
name: Check Licenses
runs-on: ubuntu-slim
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
- uses: ./.github/actions/setup_gradle
- name: "Check licenses"
run: ./gradlew licensee
- name: "Create licenses summary"
if: always()
shell: bash
run: |
ERRORS=$(python './scripts/reports/collect_reports.py' --type licensee)
echo '### Licensee report' >> $GITHUB_STEP_SUMMARY
if [ -z "$ERRORS" ]; then
echo '✅ No Licensee errors found.' >> $GITHUB_STEP_SUMMARY
else
echo '❌ Some Licensee errors found:' >> $GITHUB_STEP_SUMMARY
echo '```' >> $GITHUB_STEP_SUMMARY
echo "$ERRORS" >> $GITHUB_STEP_SUMMARY
echo '```' >> $GITHUB_STEP_SUMMARY
fi
echo '' >> $GITHUB_STEP_SUMMARY
echo '---' >> $GITHUB_STEP_SUMMARY
echo '' >> $GITHUB_STEP_SUMMARY
- name: "Read results glob pattern"
if: always()
id: read-glob
shell: bash
run: |
file_path="./scripts/reports/glob_licensee.txt"
file_content="$(cat $file_path)"
echo "paths=$file_content" >> "$GITHUB_OUTPUT"
- name: "Upload results"
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f
if: always()
with:
name: reports
path: "${{ steps.read-glob.outputs.paths }}"
retention-days: 21