v0.1.1 #46
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This workflow will install Python dependencies and lint | |
name: Python package | |
on: | |
release: | |
types: [created] | |
jobs: | |
build: | |
name: Build distribution π¦ | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: "3.x" | |
- name: Install pypa/build | |
run: >- | |
python3 -m | |
pip install | |
build | |
--user | |
- name: Build a binary wheel and a source tarball | |
run: python3 -m build | |
- name: Store the distribution packages | |
uses: actions/upload-artifact@v3 | |
with: | |
name: python-package-distributions | |
path: dist/ | |
publish-to-pypi: | |
name: >- | |
Publish Python π distribution π¦ to PyPI | |
# comment this line to publish every git push | |
#if: startsWith(github.ref, 'refs/tags/') # only publish to PyPI on tag pushes | |
environment: | |
name: release | |
url: https://pypi.org/p/wayfire | |
runs-on: ubuntu-latest | |
permissions: | |
id-token: write # IMPORTANT: mandatory for trusted publishing | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v3 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install | |
if: github.event_name == 'release' | |
run: | | |
python -m pip install --upgrade pip | |
sudo apt-get install libdbus-1-dev | |
pip install -r requirements.txt | |
pip install setuptools wheel | |
python3 -m pip install . | |
python -m pip install -U build | |
python3 -m build | |
- name: Download all the dists | |
uses: actions/download-artifact@v3 | |
with: | |
name: python-package-distributions | |
path: dist/ | |
- name: Publish distribution π¦ to PyPI | |
uses: pypa/gh-action-pypi-publish@release/v1 | |