Skip to content

Commit

Permalink
Merge branch 'main' of https://github.com/jozu-ai/pykitops
Browse files Browse the repository at this point in the history
  • Loading branch information
brett-hodges committed Nov 19, 2024
2 parents ab533d3 + da12dc4 commit 3879456
Showing 1 changed file with 59 additions and 0 deletions.
59 changes: 59 additions & 0 deletions .github/workflows/build-deploy-all.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
name: Build and Deploy Package and Docs

on:
push:
branches:
- main
pull_request:
branches:
- main

jobs:
build-and-publish:
runs-on: ubuntu-latest

env:
PYPI_USERNAME: ${{ secrets.PYPI_USERNAME }}
PYPI_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

steps:
# Checkout the repository
- name: Check out repository
uses: actions/checkout@v4

# Set up Python
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.10'

# Install dependencies
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install hatch twine mkdocs mkdocs-material bump2version
# Bump version
- name: Bump version and push tag
run: |
bump2version patch # You can specify 'patch', 'minor', or 'major' based on your versioning needs
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

# Build the package distributables and publish to PyPI
- name: Build package
run: |
hatch build
- name: Publish package to PyPI
run: twine upload dist/*
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}

# Build and deploy mkdocs to GitHub Pages
- name: Build and deploy mkdocs
run: |
mkdocs build
mkdocs gh-deploy --force

0 comments on commit 3879456

Please sign in to comment.