Skip to content

bump: version 1.1.4 → 1.2.0 #209

bump: version 1.1.4 → 1.2.0

bump: version 1.1.4 → 1.2.0 #209

Workflow file for this run

# This workflow builds the package, installs it, and tests basic functionality
name: Build and Test Package
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
jobs:
test-build-package:
name: Test package build
runs-on: ubuntu-latest
if: "!startsWith(github.event.head_commit.message, 'bump:')"
env:
PYTHON_VERSION: 3.13
steps:
- name: Check out the repo
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
- name: Install uv
uses: astral-sh/setup-uv@85856786d1ce8acfbcc2f13a5f3fbd6b938f9f41 # v7.1.2
- name: Build the package
run: uv build --python $PYTHON_VERSION
- name: List built artifacts
run: ls -la dist/
- name: Install the built wheel
run: |
uv venv --python $PYTHON_VERSION
# Find the wheel file and install it
WHEEL_FILE=$(ls dist/*.whl | head -1)
echo "Installing wheel: $WHEEL_FILE"
uv pip install "$WHEEL_FILE"
- name: Test --version flag
run: |
# Test that the CLI is available and --version works
uv run lightman-ai --version
should-test-docker-build:
permissions:
contents: read
pull-requests: read
name: Check if should `test_docker_build` run
runs-on: ubuntu-latest
if: "!startsWith(github.event.head_commit.message, 'bump:')"
steps:
- name: Check out the repo
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
- name: Check if Dockerfile changed
uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2
id: docker-changes
with:
filters: |
docker:
- 'Dockerfile'
- '.dockerignore'
workflow:
- ./.github/actions/docker-build/action.yml
outputs:
docker: ${{ steps.docker-changes.outputs.docker }}
workflow: ${{ steps.docker-changes.outputs.workflow }}
test-docker-build:
needs: [should-test-docker-build]
name: Test Docker build
runs-on: ubuntu-latest
if: (needs.should-test-docker-build.outputs.workflow == 'true' || needs.should-test-docker-build.outputs.docker == 'true') && !startsWith(github.event.head_commit.message, 'bump:')
permissions:
contents: read
packages: read
steps:
- name: Check out the repo
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
- name: Log in to GitHub Container Registry
uses: docker/login-action@5e57cd118135c172c3672efd75eb46360885c0ef # v3.6.0
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build image
uses: ./.github/actions/docker-build
with:
context: .
file: ./Dockerfile
push: false
platforms: linux/amd64,linux/arm64
cache-from: type=registry,ref=ghcr.io/elementsinteractive/lightman-ai:buildcache