Skip to content

Commit

Permalink
Added automatic PyPI publishing (#55)
Browse files Browse the repository at this point in the history
  • Loading branch information
klemen1999 authored Sep 4, 2024
1 parent db9c519 commit 6448b1c
Showing 1 changed file with 38 additions and 0 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/python-publish.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Upload Python Package

on:
workflow_dispatch:
release:
types: [published]

permissions:
contents: read

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: '3.8'
cache: pip

- name: Install dependencies
run: pip install build pydoctor

- name: Generate docs
run: |
curl -L "https://raw.githubusercontent.com/luxonis/python-api-analyzer-to-json/main/gen-docs.py" -o "gen-docs.py"
python gen-docs.py depthai_nodes
- name: Build package
run: python -m build

- name: Publish package
uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}

0 comments on commit 6448b1c

Please sign in to comment.