Skip to content

Azure OpenAI Finetuning example (#256) #131

Azure OpenAI Finetuning example (#256)

Azure OpenAI Finetuning example (#256) #131

Workflow file for this run

name: Deploy Documentation
on:
push:
branches:
- main
tags:
- 'v*'
workflow_dispatch:
concurrency:
group: docs-deploy
cancel-in-progress: false
permissions:
contents: write
pages: write
id-token: write
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-python@v6
with:
python-version: '3.12'
- uses: astral-sh/setup-uv@v7
with:
enable-cache: true
- name: Sync dependencies
run: uv sync --frozen --no-default-groups --group dev
- name: Configure Git
run: |
git config --global user.name "GitHub Actions"
git config --global user.email "[email protected]"
- name: Get version and commit
id: version
run: |
if [[ $GITHUB_REF == refs/tags/* ]]; then
VERSION=${GITHUB_REF#refs/tags/v}
SOURCE_COMMIT=${GITHUB_SHA}
else
VERSION=$(python -c "import tomllib; print(tomllib.load(open('pyproject.toml', 'rb'))['project']['version'])")
SOURCE_COMMIT=${GITHUB_SHA}
fi
echo "version=$VERSION" >> $GITHUB_OUTPUT
echo "SOURCE_COMMIT=$SOURCE_COMMIT" >> $GITHUB_ENV
- name: Deploy versioned docs
if: startsWith(github.ref, 'refs/tags/')
run: |
uv run --locked --no-sync mike deploy --push --update-aliases ${{ steps.version.outputs.version }} stable
- name: Deploy dev docs
if: github.ref == 'refs/heads/main'
run: |
uv run --locked --no-sync mike deploy --push latest
# Always set stable to default
uv run --locked --no-sync mike set-default --push stable