From 046945539a92d1b1fcabf7e482f700f2409084e0 Mon Sep 17 00:00:00 2001 From: krmax44 Date: Mon, 16 Sep 2024 19:00:46 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=91=B7=20use=20uv=20in=20translation=20pr?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/translations.yml | 30 +++++++++++++++++------------- 1 file changed, 17 insertions(+), 13 deletions(-) diff --git a/.github/workflows/translations.yml b/.github/workflows/translations.yml index 4d6f82d06..8e538f9f2 100644 --- a/.github/workflows/translations.yml +++ b/.github/workflows/translations.yml @@ -18,20 +18,24 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 - with: - python-version: '3.10' - cache: 'pip' - cache-dependency-path: | - setup.py - requirements.txt + - name: Setup uv + uses: astral-sh/setup-uv@v2 - name: Install system-level dependencies - run: sudo apt-get update && sudo apt-get install libxml2-dev libxslt1-dev python3-dev libgdal-dev gdal-bin libmagic-dev libmagickwand-dev gettext libpoppler-cpp-dev - - name: Install dependencies + run: sudo apt-get update && sudo apt-get install gettext + - name: Setup uv + uses: astral-sh/setup-uv@v2 + with: + enable-cache: true + cache-dependency-glob: | + requirements*.txt + pyproject.toml + - name: Setup venv run: | - python -m pip install --upgrade pip pip-tools - pip-sync requirements.txt - pip install -e . + uv venv --python 3.12 + source .venv/bin/activate + echo PATH=$PATH >> $GITHUB_ENV + - name: Install dependencies + run: uv pip install "django<5" - name: Setup Git run: | git config user.name "fdsbot" @@ -42,4 +46,4 @@ jobs: run: | git add **/django.po || true git commit -m "💬 update translation messages" || true - git push -u origin main:weblate-source --force + # git push -u origin main:weblate-source --force