mirror of
https://github.com/django-q2/django-q2.git
synced 2026-09-15 13:37:56 +08:00
33 lines
804 B
YAML
33 lines
804 B
YAML
name: Release
|
|
|
|
on:
|
|
push:
|
|
tags:
|
|
- '*'
|
|
|
|
jobs:
|
|
build:
|
|
if: github.repository == 'GDay/django-q2'
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v2
|
|
with:
|
|
python-version: 3.8
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
apt-get update
|
|
apt-get -y install gettext
|
|
python -m pip install pip setuptools django poetry
|
|
# compile messages to get .mo files
|
|
django-admin compilemessages
|
|
- name: Build and publish package
|
|
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
|
|
run: poetry --build --username=__token__ --password=${{ secrets.PYPI_TOKEN }} publish
|