Skip to content

Commit

Permalink
chore(ci): Changed github workflows to have a separate release workflow.
Browse files Browse the repository at this point in the history
Now we build with python 3.9, our oldest supported python version.
  • Loading branch information
lino committed Oct 3, 2024
1 parent 3310ae7 commit 1582a15
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 19 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Release

on:
push:
tags:
- '*'

jobs:
build:
if: github.repository == 'jazzband/django-recurrence'
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Set up PDM for Python 3.9
uses: pdm-project/setup-pdm@v4
with:
python-version: 3.9

- name: Install dependencies
run: |
pdm sync -d -G dev
- name: Build wheels and sdist
run: |
pdm build
- name: Upload packages to Jazzband
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: jazzband
password: ${{ secrets.JAZZBAND_RELEASE_KEY }}
repository_url: https://jazzband.co/projects/dj-database-url/upload
19 changes: 0 additions & 19 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,22 +85,3 @@ jobs:
dist/*.whl
dist/*.tar.gz
release:
needs:
- build
runs-on: ubuntu-latest
steps:
- name: Download artifacts
uses: actions/download-artifact@v4
with:
name: wheels
path: dist

- name: Upload packages to Jazzband
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@release/v1.8
with:
user: jazzband
password: ${{ secrets.JAZZBAND_RELEASE_KEY }}
repository_url: https://jazzband.co/projects/django-recurrence/upload

0 comments on commit 1582a15

Please sign in to comment.