Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 29 additions & 7 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
# This workflows will upload a Python Package using Twine when a release is created
# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries
# This workflow will build and upload a Python package to PyPI when a release is created

name: Publish

Expand All @@ -8,12 +7,35 @@ on:
types: [created]

jobs:
deploy:
build:
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- uses: actions/checkout@v7
with:
fetch-depth: 0
persist-credentials: false
- uses: astral-sh/setup-uv@v7
- name: Build
run: uv build
- name: Upload distributions
uses: actions/upload-artifact@v4
with:
name: dist
path: dist/

publish:
needs: build
runs-on: ubuntu-latest
permissions:
id-token: write
steps:
- uses: actions/checkout@v3
- name: Build and publish to pypi
uses: JRubics/poetry-publish@v2.0
- uses: astral-sh/setup-uv@v7
- name: Download distributions
uses: actions/download-artifact@v4
with:
pypi_token: ${{ secrets.PYPI_TOKEN }}
name: dist
path: dist/
- name: Publish
run: uv publish
26 changes: 12 additions & 14 deletions .github/workflows/python-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,32 +15,30 @@ jobs:
strategy:
matrix:
python-version:
- "3.9"
- "3.10"
- "3.11"
- "3.12"
- "3.13"
- "3.14"
- "pypy-3.9"
- "pypy-3.10"
- "pypy-3.11"

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v7
- uses: astral-sh/setup-uv@v7
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
uses: actions/setup-python@v7
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install poetry
poetry install --with test
run: uv sync
- name: Lint
run: |
poetry run flake8 pycron --max-line-length=88
poetry run pylint pycron
poetry run mypy pycron
uv run flake8 pycron --max-line-length=88
uv run pylint pycron
- name: Type check
if: ${{ !startsWith(matrix.python-version, 'pypy') }}
run: uv run mypy pycron
- name: Run tests
run: |
poetry run coverage run -m unittest discover -b
poetry run coverage report --fail-under=100
uv run coverage run -m unittest discover -b
uv run coverage report --fail-under=100
1 change: 0 additions & 1 deletion MANIFEST.in

This file was deleted.

Loading
Loading