Skip to content

Commit

Permalink
feat: automate release process
Browse files Browse the repository at this point in the history
- use uv to install dependencies for faster CI
- add new workflow to build and publish releases on tags
  • Loading branch information
nijel committed Oct 25, 2024
1 parent 73bfb5d commit 124c6e5
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 1 deletion.
21 changes: 21 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: test

on:
push:
pull_request:

jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- uses: astral-sh/setup-uv@v3

- name: Build
run: uv build

- name: Publish package
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags') && github.repository == 'WeblateOrg/language-data'
run: uv publish --trusted-publishing always
4 changes: 3 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,10 @@ jobs:
with:
python-version: ${{ matrix.python-version }}

- uses: astral-sh/setup-uv@v3

- name: Install
run: pip install -e .[tests]
run: uv pip install --system -e .[tests]

- name: Test
run: pytest

0 comments on commit 124c6e5

Please sign in to comment.