Files
mealie/.github/workflows/build-package.yml
T

59 lines
1.3 KiB
YAML

name: Build Package
on:
workflow_call:
inputs:
tag:
required: true
type: string
ref:
required: false
type: string
jobs:
build-package:
name: Build frontend and wheel
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v6
with:
ref: ${{ inputs.ref || github.sha }}
- name: Set up tools
uses: ./.github/actions/setup-tools
with:
tools: python node pnpm uv
cache-pnpm-store: true
- name: Install dependencies 👨🏻‍💻
run: pnpm install --prefer-offline
working-directory: "frontend"
- name: Run Build 🚚
run: pnpm generate
working-directory: "frontend"
- name: Copy the frontend into the package
run: |
rm -rf mealie/frontend
cp -a frontend/dist mealie/frontend
- name: Override __init__.py
run: |
echo "__version__ = \"${{ inputs.tag }}\"" > ./mealie/__init__.py
- name: Build package and requirements files
env:
SKIP_PACKAGE_DEPS: true
run: |
mise run py:package
- name: Archive built package
uses: actions/upload-artifact@v6
with:
name: backend-dist
path: dist
retention-days: 5