feat(model): Handle path excludes when resolving license files #182
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: Release | |
| on: | |
| push: | |
| tags: | |
| - "[0-9]+.[0-9]+.[0-9]+" | |
| workflow_dispatch: | |
| inputs: | |
| tag: | |
| description: "Git tag to release from" | |
| required: true | |
| type: string | |
| env: | |
| GRADLE_OPTS: -Dorg.gradle.daemon=false | |
| jobs: | |
| publish: | |
| env: | |
| ORT_VERSION: ${{ inputs.tag || github.ref_name }} | |
| permissions: | |
| attestations: write | |
| contents: write | |
| id-token: write | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - name: Checkout Repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| ref: ${{ env.ORT_VERSION }} | |
| fetch-depth: 0 | |
| - name: Setup Gradle | |
| uses: gradle/actions/setup-gradle@50e97c2cd7a37755bbfafc9c5b7cafaece252f6e # v6.1.0 | |
| with: | |
| dependency-graph: generate-and-submit | |
| - name: Build ORT Distributions | |
| env: | |
| ORG_GRADLE_PROJECT_signingInMemoryKey: ${{ secrets.SIGNING_KEY }} | |
| ORG_GRADLE_PROJECT_signingInMemoryKeyPassword: ${{ secrets.SIGNING_PASSWORD }} | |
| run: ./gradlew :cli:signDistTar :cli:signDistZip :cli-helper:signDistTar :cli-helper:signDistZip | |
| - name: Generate Release Notes | |
| run: ./gradlew -q printChangeLog > RELEASE_NOTES.md | |
| - name: Create GitHub Release | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| run: | | |
| gh release create $ORT_VERSION --notes-file RELEASE_NOTES.md \ | |
| ./cli/build/distributions/ort-$ORT_VERSION.{tgz,zip}* \ | |
| ./cli-helper/build/distributions/orth-$ORT_VERSION.{tgz,zip}* | |
| - name: Attest Build Provenance | |
| uses: actions/attest-build-provenance@a2bbfa25375fe432b6a289bc6b6cd05ecd0c4c32 # v4.1.0 | |
| with: | |
| subject-path: | | |
| ./cli/build/distributions/ort-${{ env.ORT_VERSION }}.tgz | |
| ./cli/build/distributions/ort-${{ env.ORT_VERSION }}.zip | |
| ./cli-helper/build/distributions/orth-${{ env.ORT_VERSION }}.tgz | |
| ./cli-helper/build/distributions/orth-${{ env.ORT_VERSION }}.zip | |
| - name: Publish to Maven Central | |
| env: | |
| GITHUB_DEPENDENCY_GRAPH_REF: refs/heads/main | |
| ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.MAVEN_CENTRAL_USERNAME }} | |
| ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.MAVEN_CENTRAL_PASSWORD }} | |
| ORG_GRADLE_PROJECT_signAllPublications: true | |
| ORG_GRADLE_PROJECT_signingInMemoryKey: ${{ secrets.SIGNING_KEY }} | |
| ORG_GRADLE_PROJECT_signingInMemoryKeyPassword: ${{ secrets.SIGNING_PASSWORD }} | |
| ORG_GRADLE_PROJECT_SONATYPE_CONNECT_TIMEOUT_SECONDS: 300 | |
| ORG_GRADLE_PROJECT_SONATYPE_CLOSE_TIMEOUT_SECONDS: 3600 | |
| run: ./gradlew publishAndReleaseToMavenCentral |