# Generated from xtask::workflows::run_license_checks
# Rebuild with `cargo xtask workflows`.
name: run_license_checks
env:
  CARGO_TERM_COLOR: always
  RUST_BACKTRACE: '1'
  CARGO_INCREMENTAL: '0'
on:
  pull_request:
    branches:
    - '**'
    paths:
    - Cargo.lock
    - '**/Cargo.lock'
    - script/*licenses
    - '**/LICENSE*'
    - .github/workflows/run_license_checks.yml
  push:
    branches:
    - main
    - v[0-9]+.[0-9]+.x
    paths:
    - Cargo.lock
    - '**/Cargo.lock'
    - script/*licenses
    - '**/LICENSE*'
    - .github/workflows/run_license_checks.yml
jobs:
  check_licenses:
    runs-on: namespace-profile-2x4-ubuntu-2404
    steps:
    - name: steps::checkout_repo
      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
      with:
        clean: false
    - name: ./script/check-licenses
      run: ./script/check-licenses
      shell: bash -euxo pipefail {0}
  build_licenses:
    runs-on: namespace-profile-4x8-ubuntu-2204
    steps:
    - name: steps::checkout_repo
      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
      with:
        clean: false
    - name: ./script/generate-licenses
      run: ./script/generate-licenses
      shell: bash -euxo pipefail {0}
concurrency:
  group: ${{ github.workflow }}-${{ github.ref_name }}-${{ github.ref_name == 'main' && github.sha || 'anysha' }}
  cancel-in-progress: true
