Skip to content

ci: Switch to actions/setup-python@v3 #34

ci: Switch to actions/setup-python@v3

ci: Switch to actions/setup-python@v3 #34

Workflow file for this run

---
name: publish
# Actions for any tag.
# -----------------
# Control variables (GitHub Secrets)
# -----------------
#
# At the GitHub 'organisation' or 'project' level you must have the following
# GitHub 'Repository Secrets' defined (i.e. via 'Settings -> Secrets'): -
#
# PYPI_USERNAME
# PYPI_TOKEN
#
# -----------
# Environment (GitHub Environments)
# -----------
#
# Environment (none)
on:
push:
tags:
- '**'
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Inject slug/short variables
uses: rlespinasse/[email protected]
- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r package-requirements.txt
- name: Lint
run: pylint data_manager_metadata
- name: Build
run: |
sed -i s/"_METADATA_VERSION: str = '0.0.0'"/"_METADATA_VERSION: str = '${TAG:-0.0.0}'"/ data_manager_metadata/metadata.py
python setup.py bdist_wheel
- name: Publish
uses: pypa/gh-action-pypi-publish@master
with:
user: ${{ secrets.PYPI_USERNAME }}
password: ${{ secrets.PYPI_TOKEN }}