Build packages #71
This file contains 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
# Copyright 2024 The IREE Authors | |
# | |
# Licensed under the Apache License v2.0 with LLVM Exceptions. | |
# See https://llvm.org/LICENSE.txt for license information. | |
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception | |
name: Build packages | |
on: | |
workflow_dispatch: | |
schedule: | |
# Runs at 05:00 AM UTC, which is 9:00 PM PST (UTC-8) / 10:00 PM PDT (UTC-7) | |
# This lines up with https://github.com/iree-org/iree/blob/main/.github/workflows/schedule_candidate_release.yml | |
# Downstream projects using nightly releases should expect IREE and | |
# iree-turbine packages to all be available around the same time. This | |
# build is much faster than the IREE build though. | |
- cron: '0 5 * * *' | |
jobs: | |
build_packages: | |
if: ${{ github.repository_owner == 'iree-org' || github.event_name != 'schedule' }} | |
runs-on: ubuntu-22.04 | |
permissions: | |
contents: write | |
steps: | |
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
- name: "Setting up Python" | |
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0 | |
with: | |
python-version: 3.11 | |
- name: Install dependencies | |
run: pip install -r ./build_tools/requirements-packaging.txt | |
- name: Build iree-turbine release candidate | |
run: | | |
./build_tools/compute_local_version.py \ | |
-rc --write-json \ | |
--version-suffix ".${{ github.run_number }}" | |
./build_tools/build_release.py --no-download | |
- name: Upload python wheels | |
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0 | |
with: | |
if-no-files-found: error | |
name: snapshot | |
path: wheelhouse | |
- name: Release python wheels | |
uses: ncipollo/release-action@cdcc88a9acf3ca41c16c37bb7d21b9ad48560d87 # v1.15.0 | |
with: | |
artifacts: wheelhouse/*.whl | |
tag: "dev-wheels" | |
name: "dev-wheels" | |
body: "Automatic snapshot release of iree-turbine python wheels." | |
removeArtifacts: false | |
allowUpdates: true | |
replacesArtifacts: true | |
makeLatest: false |