name: Pull Request # trunk-ignore(yamllint/truthy) on: [push, pull_request] concurrency: group: ${{ github.head_ref || github.run_id }} cancel-in-progress: true permissions: read-all jobs: check_distribute_and_build: runs-on: ubuntu-latest name: Check and build distribute if needed steps: - uses: actions/checkout@v4 - name: Check if distribute directory exists id: check_distribute run: | if [ ! -d "distribute" ]; then echo "distribute_exists=false" >> $GITHUB_OUTPUT else echo "distribute_exists=true" >> $GITHUB_OUTPUT fi - name: Trigger build-distribute workflow if: steps.check_distribute.outputs.distribute_exists == 'false' uses: ./.github/workflows/build-distribute.yml trunk_check: name: Trunk Code Quality Runner runs-on: ubuntu-latest permissions: checks: write # For trunk to post annotations contents: read # For repo checkout steps: - name: Checkout uses: actions/checkout@v3 - name: Trunk Code Quality uses: trunk-io/trunk-action@v1