From f7a3d926240cfabe392eec33d6266873079e4337 Mon Sep 17 00:00:00 2001 From: Andre Weber Date: Fri, 17 Nov 2023 08:07:29 +0100 Subject: [PATCH 1/2] feature: Replace "Check-Dash" GitHub Action with Kuksa Shared Action Closes: #37 Signed-Off-By: Andre Weber --- .github/actions/check-dash/action.yml | 30 --------------------------- .github/workflows/build.yaml | 8 ------- .github/workflows/dash.yaml | 28 +++++++++++++++++++++++++ 3 files changed, 28 insertions(+), 38 deletions(-) delete mode 100644 .github/actions/check-dash/action.yml create mode 100644 .github/workflows/dash.yaml diff --git a/.github/actions/check-dash/action.yml b/.github/actions/check-dash/action.yml deleted file mode 100644 index d5df6597..00000000 --- a/.github/actions/check-dash/action.yml +++ /dev/null @@ -1,30 +0,0 @@ -name: Checking dependencies with dash-license tool -description: Check an input file via dash, and archive report. Print output in build step summary. Requires wget and an JRE on the runner - -inputs: - dashinput: - required: true - type: string - description: "Dash Input file" - - -runs: - using: "composite" - steps: - - name: "Run Dash" - shell: bash - run: | - wget -O dash.jar "https://repo.eclipse.org/service/local/artifact/maven/redirect?r=dash-licenses&g=org.eclipse.dash&a=org.eclipse.dash.licenses&v=LATEST" - java -jar dash.jar -summary ${{ inputs.dashinput }}.report ${{ inputs.dashinput }} > ${{ inputs.dashinput }}.out 2>&1 || true - echo -e "Dash output: \n\`\`\` " >> $GITHUB_STEP_SUMMARY - cat ${{ inputs.dashinput }}.out >> $GITHUB_STEP_SUMMARY - echo -e "\n\`\`\`" - - - name: "Archive dash artifacts" - uses: actions/upload-artifact@v3 - with: - name: "Dash data" - path: | - ${{ inputs.dashinput }} - ${{ inputs.dashinput }}.report - ${{ inputs.dashinput }}.out diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index faea7426..ac6dffc2 100755 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -19,14 +19,6 @@ jobs: - name: Setup Gradle uses: gradle/gradle-build-action@v2 - - name: Create Dash Dependency Report - run: ./gradlew mergeDashFiles - - - name: Dash license check - uses: ./.github/actions/check-dash - with: - dashinput: ${{github.workspace}}/build/oss/all/all-dependencies.txt - - name: Run 'assemble' with Gradle Wrapper run: ./gradlew assemble diff --git a/.github/workflows/dash.yaml b/.github/workflows/dash.yaml new file mode 100644 index 00000000..a74fb554 --- /dev/null +++ b/.github/workflows/dash.yaml @@ -0,0 +1,28 @@ +name: dash + +on: + pull_request + +jobs: + check-dash: + runs-on: ubuntu-latest + steps: + + - name: Checkout code + uses: actions/checkout@v3 + + - uses: actions/setup-java@v3 + with: + distribution: 'temurin' + java-version: '17' + + - name: Setup Gradle + uses: gradle/gradle-build-action@v2 + + - name: Create Dash Dependency Report + run: ./gradlew mergeDashFiles + + - name: Dash license check + uses: eclipse-kuksa/kuksa-actions/check-dash@2 + with: + dashinput: ${{github.workspace}}/build/oss/all/all-dependencies.txt From 18b513f3be9641c893dd2ed73352e82b54dc65c9 Mon Sep 17 00:00:00 2001 From: Andre Weber Date: Fri, 17 Nov 2023 08:08:26 +0100 Subject: [PATCH 2/2] chore: Update SPDX Version to 2 --- .github/workflows/check_license.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/check_license.yaml b/.github/workflows/check_license.yaml index e366c375..f400b608 100755 --- a/.github/workflows/check_license.yaml +++ b/.github/workflows/check_license.yaml @@ -21,8 +21,8 @@ jobs: - name: Set license run: | echo "licenses=Apache-2.0" >> $GITHUB_ENV - - - uses: eclipse-kuksa/kuksa-actions/.github/actions/spdx@1 + + - uses: eclipse-kuksa/kuksa-actions/spdx@2 with: files: "${{ env.files }}" licenses: "${{ env.licenses }}"