Skip to content

Commit

Permalink
Workflow to check compatibility for upstream (#233)
Browse files Browse the repository at this point in the history
  • Loading branch information
jackalcooper authored Dec 5, 2023
1 parent 53f6473 commit 5c7d74b
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 4 deletions.
12 changes: 8 additions & 4 deletions .github/workflows/elixir.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,19 @@ on:
- "**/*.md"
- "LICENSE*"

schedule:
- cron: "00 05 * * *"

workflow_dispatch:
inputs:
mlir_wheel_version:
description: "mlir wheel version to install"
required: false

workflow_call:
inputs:
mlir_wheel_version:
description: "mlir wheel version to install"
type: string
required: false

permissions:
contents: read

Expand Down Expand Up @@ -61,7 +65,7 @@ jobs:
python3 -m pip install mlir=="${{ inputs.mlir_wheel_version }}" -f https://makslevental.github.io/wheels -U
echo "LLVM_CONFIG_PATH=$(python3 -c 'import mlir;print(mlir.__path__[0])')/bin/llvm-config" >> "$GITHUB_ENV"
- name: Install MLIR (latest)
if: github.event_name == 'schedule' || (github.event_name == 'workflow_dispatch' && inputs.mlir_wheel_version == '') || (github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'use-latest-mlir'))
if: inputs.mlir_wheel_version == 'latest' || (github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'use-latest-mlir'))
run: |
python3 -m pip install mlir -f https://makslevental.github.io/wheels -U
echo "LLVM_CONFIG_PATH=$(python3 -c 'import mlir;print(mlir.__path__[0])')/bin/llvm-config" >> "$GITHUB_ENV"
Expand Down
27 changes: 27 additions & 0 deletions .github/workflows/upstream.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Check Upstream

on:
schedule:
- cron: "00 05 * * *"
workflow_dispatch:
inputs:
mlir_wheel_version:
description: "mlir wheel version to install"
required: false
push:
branches:
- "upstream/*"

concurrency:
group: check-upstream-${{ github.ref }}-${{ inputs.mlir_wheel_version }}
cancel-in-progress: true

jobs:
mlir:
name: Latest MLIR
permissions:
contents: read
pull-requests: write
uses: ./.github/workflows/elixir.yml
with:
mlir_wheel_version: ${{ inputs.mlir_wheel_version || 'latest' }}

0 comments on commit 5c7d74b

Please sign in to comment.